Left Termination of the query pattern perm_in_2(g, a) w.r.t. the given Prolog program could not be shown:



Prolog
  ↳ PrologToPiTRSProof
  ↳ PrologToPiTRSProof

Clauses:

app1(.(X0, X), Y, .(X0, Z)) :- app1(X, Y, Z).
app1([], Y, Y).
app2(.(X0, X), Y, .(X0, Z)) :- app2(X, Y, Z).
app2([], Y, Y).
perm(X, .(X0, Y)) :- ','(app1(X1, .(X0, X2), X), ','(app2(X1, X2, Z), perm(Z, Y))).
perm([], []).

Queries:

perm(g,a).

We use the technique of [30]. With regard to the inferred argument filtering the predicates were used in the following modes:
perm_in: (b,f) (f,f)
app1_in: (f,b,b) (f,b,f)
app2_in: (b,f,f) (f,f,f)
Transforming Prolog into the following Term Rewriting System:
Pi-finite rewrite system:
The TRS R consists of the following rules:

perm_in_ga(X, .(X0, Y)) → U3_ga(X, X0, Y, app1_in_agg(X1, .(X0, X2), X))
app1_in_agg(.(X0, X), Y, .(X0, Z)) → U1_agg(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga(.(X0, X), Y, .(X0, Z)) → U1_aga(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga([], Y, Y) → app1_out_aga([], Y, Y)
U1_aga(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_aga(.(X0, X), Y, .(X0, Z))
U1_agg(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_agg(.(X0, X), Y, .(X0, Z))
app1_in_agg([], Y, Y) → app1_out_agg([], Y, Y)
U3_ga(X, X0, Y, app1_out_agg(X1, .(X0, X2), X)) → U4_ga(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
app2_in_gaa(.(X0, X), Y, .(X0, Z)) → U2_gaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa(.(X0, X), Y, .(X0, Z)) → U2_aaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa([], Y, Y) → app2_out_aaa([], Y, Y)
U2_aaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_aaa(.(X0, X), Y, .(X0, Z))
U2_gaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_gaa(.(X0, X), Y, .(X0, Z))
app2_in_gaa([], Y, Y) → app2_out_gaa([], Y, Y)
U4_ga(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_ga(X, X0, Y, perm_in_aa(Z, Y))
perm_in_aa(X, .(X0, Y)) → U3_aa(X, X0, Y, app1_in_aga(X1, .(X0, X2), X))
U3_aa(X, X0, Y, app1_out_aga(X1, .(X0, X2), X)) → U4_aa(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
U4_aa(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_aa(X, X0, Y, perm_in_aa(Z, Y))
perm_in_aa([], []) → perm_out_aa([], [])
U5_aa(X, X0, Y, perm_out_aa(Z, Y)) → perm_out_aa(X, .(X0, Y))
U5_ga(X, X0, Y, perm_out_aa(Z, Y)) → perm_out_ga(X, .(X0, Y))
perm_in_ga([], []) → perm_out_ga([], [])

The argument filtering Pi contains the following mapping:
perm_in_ga(x1, x2)  =  perm_in_ga(x1)
U3_ga(x1, x2, x3, x4)  =  U3_ga(x4)
app1_in_agg(x1, x2, x3)  =  app1_in_agg(x2, x3)
.(x1, x2)  =  .
U1_agg(x1, x2, x3, x4, x5)  =  U1_agg(x5)
app1_in_aga(x1, x2, x3)  =  app1_in_aga(x2)
U1_aga(x1, x2, x3, x4, x5)  =  U1_aga(x5)
app1_out_aga(x1, x2, x3)  =  app1_out_aga(x1, x3)
app1_out_agg(x1, x2, x3)  =  app1_out_agg(x1)
U4_ga(x1, x2, x3, x4, x5, x6)  =  U4_ga(x6)
app2_in_gaa(x1, x2, x3)  =  app2_in_gaa(x1)
U2_gaa(x1, x2, x3, x4, x5)  =  U2_gaa(x5)
app2_in_aaa(x1, x2, x3)  =  app2_in_aaa
U2_aaa(x1, x2, x3, x4, x5)  =  U2_aaa(x5)
app2_out_aaa(x1, x2, x3)  =  app2_out_aaa(x1)
app2_out_gaa(x1, x2, x3)  =  app2_out_gaa
[]  =  []
U5_ga(x1, x2, x3, x4)  =  U5_ga(x4)
perm_in_aa(x1, x2)  =  perm_in_aa
U3_aa(x1, x2, x3, x4)  =  U3_aa(x4)
U4_aa(x1, x2, x3, x4, x5, x6)  =  U4_aa(x1, x6)
U5_aa(x1, x2, x3, x4)  =  U5_aa(x1, x4)
perm_out_aa(x1, x2)  =  perm_out_aa(x1, x2)
perm_out_ga(x1, x2)  =  perm_out_ga(x2)

Infinitary Constructor Rewriting Termination of PiTRS implies Termination of Prolog



↳ Prolog
  ↳ PrologToPiTRSProof
PiTRS
      ↳ DependencyPairsProof
  ↳ PrologToPiTRSProof

Pi-finite rewrite system:
The TRS R consists of the following rules:

perm_in_ga(X, .(X0, Y)) → U3_ga(X, X0, Y, app1_in_agg(X1, .(X0, X2), X))
app1_in_agg(.(X0, X), Y, .(X0, Z)) → U1_agg(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga(.(X0, X), Y, .(X0, Z)) → U1_aga(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga([], Y, Y) → app1_out_aga([], Y, Y)
U1_aga(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_aga(.(X0, X), Y, .(X0, Z))
U1_agg(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_agg(.(X0, X), Y, .(X0, Z))
app1_in_agg([], Y, Y) → app1_out_agg([], Y, Y)
U3_ga(X, X0, Y, app1_out_agg(X1, .(X0, X2), X)) → U4_ga(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
app2_in_gaa(.(X0, X), Y, .(X0, Z)) → U2_gaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa(.(X0, X), Y, .(X0, Z)) → U2_aaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa([], Y, Y) → app2_out_aaa([], Y, Y)
U2_aaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_aaa(.(X0, X), Y, .(X0, Z))
U2_gaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_gaa(.(X0, X), Y, .(X0, Z))
app2_in_gaa([], Y, Y) → app2_out_gaa([], Y, Y)
U4_ga(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_ga(X, X0, Y, perm_in_aa(Z, Y))
perm_in_aa(X, .(X0, Y)) → U3_aa(X, X0, Y, app1_in_aga(X1, .(X0, X2), X))
U3_aa(X, X0, Y, app1_out_aga(X1, .(X0, X2), X)) → U4_aa(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
U4_aa(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_aa(X, X0, Y, perm_in_aa(Z, Y))
perm_in_aa([], []) → perm_out_aa([], [])
U5_aa(X, X0, Y, perm_out_aa(Z, Y)) → perm_out_aa(X, .(X0, Y))
U5_ga(X, X0, Y, perm_out_aa(Z, Y)) → perm_out_ga(X, .(X0, Y))
perm_in_ga([], []) → perm_out_ga([], [])

The argument filtering Pi contains the following mapping:
perm_in_ga(x1, x2)  =  perm_in_ga(x1)
U3_ga(x1, x2, x3, x4)  =  U3_ga(x4)
app1_in_agg(x1, x2, x3)  =  app1_in_agg(x2, x3)
.(x1, x2)  =  .
U1_agg(x1, x2, x3, x4, x5)  =  U1_agg(x5)
app1_in_aga(x1, x2, x3)  =  app1_in_aga(x2)
U1_aga(x1, x2, x3, x4, x5)  =  U1_aga(x5)
app1_out_aga(x1, x2, x3)  =  app1_out_aga(x1, x3)
app1_out_agg(x1, x2, x3)  =  app1_out_agg(x1)
U4_ga(x1, x2, x3, x4, x5, x6)  =  U4_ga(x6)
app2_in_gaa(x1, x2, x3)  =  app2_in_gaa(x1)
U2_gaa(x1, x2, x3, x4, x5)  =  U2_gaa(x5)
app2_in_aaa(x1, x2, x3)  =  app2_in_aaa
U2_aaa(x1, x2, x3, x4, x5)  =  U2_aaa(x5)
app2_out_aaa(x1, x2, x3)  =  app2_out_aaa(x1)
app2_out_gaa(x1, x2, x3)  =  app2_out_gaa
[]  =  []
U5_ga(x1, x2, x3, x4)  =  U5_ga(x4)
perm_in_aa(x1, x2)  =  perm_in_aa
U3_aa(x1, x2, x3, x4)  =  U3_aa(x4)
U4_aa(x1, x2, x3, x4, x5, x6)  =  U4_aa(x1, x6)
U5_aa(x1, x2, x3, x4)  =  U5_aa(x1, x4)
perm_out_aa(x1, x2)  =  perm_out_aa(x1, x2)
perm_out_ga(x1, x2)  =  perm_out_ga(x2)


Using Dependency Pairs [1,30] we result in the following initial DP problem:
Pi DP problem:
The TRS P consists of the following rules:

PERM_IN_GA(X, .(X0, Y)) → U3_GA(X, X0, Y, app1_in_agg(X1, .(X0, X2), X))
PERM_IN_GA(X, .(X0, Y)) → APP1_IN_AGG(X1, .(X0, X2), X)
APP1_IN_AGG(.(X0, X), Y, .(X0, Z)) → U1_AGG(X0, X, Y, Z, app1_in_aga(X, Y, Z))
APP1_IN_AGG(.(X0, X), Y, .(X0, Z)) → APP1_IN_AGA(X, Y, Z)
APP1_IN_AGA(.(X0, X), Y, .(X0, Z)) → U1_AGA(X0, X, Y, Z, app1_in_aga(X, Y, Z))
APP1_IN_AGA(.(X0, X), Y, .(X0, Z)) → APP1_IN_AGA(X, Y, Z)
U3_GA(X, X0, Y, app1_out_agg(X1, .(X0, X2), X)) → U4_GA(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
U3_GA(X, X0, Y, app1_out_agg(X1, .(X0, X2), X)) → APP2_IN_GAA(X1, X2, Z)
APP2_IN_GAA(.(X0, X), Y, .(X0, Z)) → U2_GAA(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
APP2_IN_GAA(.(X0, X), Y, .(X0, Z)) → APP2_IN_AAA(X, Y, Z)
APP2_IN_AAA(.(X0, X), Y, .(X0, Z)) → U2_AAA(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
APP2_IN_AAA(.(X0, X), Y, .(X0, Z)) → APP2_IN_AAA(X, Y, Z)
U4_GA(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_GA(X, X0, Y, perm_in_aa(Z, Y))
U4_GA(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → PERM_IN_AA(Z, Y)
PERM_IN_AA(X, .(X0, Y)) → U3_AA(X, X0, Y, app1_in_aga(X1, .(X0, X2), X))
PERM_IN_AA(X, .(X0, Y)) → APP1_IN_AGA(X1, .(X0, X2), X)
U3_AA(X, X0, Y, app1_out_aga(X1, .(X0, X2), X)) → U4_AA(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
U3_AA(X, X0, Y, app1_out_aga(X1, .(X0, X2), X)) → APP2_IN_GAA(X1, X2, Z)
U4_AA(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_AA(X, X0, Y, perm_in_aa(Z, Y))
U4_AA(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → PERM_IN_AA(Z, Y)

The TRS R consists of the following rules:

perm_in_ga(X, .(X0, Y)) → U3_ga(X, X0, Y, app1_in_agg(X1, .(X0, X2), X))
app1_in_agg(.(X0, X), Y, .(X0, Z)) → U1_agg(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga(.(X0, X), Y, .(X0, Z)) → U1_aga(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga([], Y, Y) → app1_out_aga([], Y, Y)
U1_aga(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_aga(.(X0, X), Y, .(X0, Z))
U1_agg(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_agg(.(X0, X), Y, .(X0, Z))
app1_in_agg([], Y, Y) → app1_out_agg([], Y, Y)
U3_ga(X, X0, Y, app1_out_agg(X1, .(X0, X2), X)) → U4_ga(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
app2_in_gaa(.(X0, X), Y, .(X0, Z)) → U2_gaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa(.(X0, X), Y, .(X0, Z)) → U2_aaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa([], Y, Y) → app2_out_aaa([], Y, Y)
U2_aaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_aaa(.(X0, X), Y, .(X0, Z))
U2_gaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_gaa(.(X0, X), Y, .(X0, Z))
app2_in_gaa([], Y, Y) → app2_out_gaa([], Y, Y)
U4_ga(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_ga(X, X0, Y, perm_in_aa(Z, Y))
perm_in_aa(X, .(X0, Y)) → U3_aa(X, X0, Y, app1_in_aga(X1, .(X0, X2), X))
U3_aa(X, X0, Y, app1_out_aga(X1, .(X0, X2), X)) → U4_aa(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
U4_aa(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_aa(X, X0, Y, perm_in_aa(Z, Y))
perm_in_aa([], []) → perm_out_aa([], [])
U5_aa(X, X0, Y, perm_out_aa(Z, Y)) → perm_out_aa(X, .(X0, Y))
U5_ga(X, X0, Y, perm_out_aa(Z, Y)) → perm_out_ga(X, .(X0, Y))
perm_in_ga([], []) → perm_out_ga([], [])

The argument filtering Pi contains the following mapping:
perm_in_ga(x1, x2)  =  perm_in_ga(x1)
U3_ga(x1, x2, x3, x4)  =  U3_ga(x4)
app1_in_agg(x1, x2, x3)  =  app1_in_agg(x2, x3)
.(x1, x2)  =  .
U1_agg(x1, x2, x3, x4, x5)  =  U1_agg(x5)
app1_in_aga(x1, x2, x3)  =  app1_in_aga(x2)
U1_aga(x1, x2, x3, x4, x5)  =  U1_aga(x5)
app1_out_aga(x1, x2, x3)  =  app1_out_aga(x1, x3)
app1_out_agg(x1, x2, x3)  =  app1_out_agg(x1)
U4_ga(x1, x2, x3, x4, x5, x6)  =  U4_ga(x6)
app2_in_gaa(x1, x2, x3)  =  app2_in_gaa(x1)
U2_gaa(x1, x2, x3, x4, x5)  =  U2_gaa(x5)
app2_in_aaa(x1, x2, x3)  =  app2_in_aaa
U2_aaa(x1, x2, x3, x4, x5)  =  U2_aaa(x5)
app2_out_aaa(x1, x2, x3)  =  app2_out_aaa(x1)
app2_out_gaa(x1, x2, x3)  =  app2_out_gaa
[]  =  []
U5_ga(x1, x2, x3, x4)  =  U5_ga(x4)
perm_in_aa(x1, x2)  =  perm_in_aa
U3_aa(x1, x2, x3, x4)  =  U3_aa(x4)
U4_aa(x1, x2, x3, x4, x5, x6)  =  U4_aa(x1, x6)
U5_aa(x1, x2, x3, x4)  =  U5_aa(x1, x4)
perm_out_aa(x1, x2)  =  perm_out_aa(x1, x2)
perm_out_ga(x1, x2)  =  perm_out_ga(x2)
U5_AA(x1, x2, x3, x4)  =  U5_AA(x1, x4)
U2_GAA(x1, x2, x3, x4, x5)  =  U2_GAA(x5)
U4_AA(x1, x2, x3, x4, x5, x6)  =  U4_AA(x1, x6)
U3_GA(x1, x2, x3, x4)  =  U3_GA(x4)
APP1_IN_AGG(x1, x2, x3)  =  APP1_IN_AGG(x2, x3)
U5_GA(x1, x2, x3, x4)  =  U5_GA(x4)
U2_AAA(x1, x2, x3, x4, x5)  =  U2_AAA(x5)
APP2_IN_GAA(x1, x2, x3)  =  APP2_IN_GAA(x1)
U4_GA(x1, x2, x3, x4, x5, x6)  =  U4_GA(x6)
APP2_IN_AAA(x1, x2, x3)  =  APP2_IN_AAA
PERM_IN_AA(x1, x2)  =  PERM_IN_AA
APP1_IN_AGA(x1, x2, x3)  =  APP1_IN_AGA(x2)
PERM_IN_GA(x1, x2)  =  PERM_IN_GA(x1)
U1_AGG(x1, x2, x3, x4, x5)  =  U1_AGG(x5)
U1_AGA(x1, x2, x3, x4, x5)  =  U1_AGA(x5)
U3_AA(x1, x2, x3, x4)  =  U3_AA(x4)

We have to consider all (P,R,Pi)-chains

↳ Prolog
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
PiDP
          ↳ DependencyGraphProof
  ↳ PrologToPiTRSProof

Pi DP problem:
The TRS P consists of the following rules:

PERM_IN_GA(X, .(X0, Y)) → U3_GA(X, X0, Y, app1_in_agg(X1, .(X0, X2), X))
PERM_IN_GA(X, .(X0, Y)) → APP1_IN_AGG(X1, .(X0, X2), X)
APP1_IN_AGG(.(X0, X), Y, .(X0, Z)) → U1_AGG(X0, X, Y, Z, app1_in_aga(X, Y, Z))
APP1_IN_AGG(.(X0, X), Y, .(X0, Z)) → APP1_IN_AGA(X, Y, Z)
APP1_IN_AGA(.(X0, X), Y, .(X0, Z)) → U1_AGA(X0, X, Y, Z, app1_in_aga(X, Y, Z))
APP1_IN_AGA(.(X0, X), Y, .(X0, Z)) → APP1_IN_AGA(X, Y, Z)
U3_GA(X, X0, Y, app1_out_agg(X1, .(X0, X2), X)) → U4_GA(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
U3_GA(X, X0, Y, app1_out_agg(X1, .(X0, X2), X)) → APP2_IN_GAA(X1, X2, Z)
APP2_IN_GAA(.(X0, X), Y, .(X0, Z)) → U2_GAA(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
APP2_IN_GAA(.(X0, X), Y, .(X0, Z)) → APP2_IN_AAA(X, Y, Z)
APP2_IN_AAA(.(X0, X), Y, .(X0, Z)) → U2_AAA(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
APP2_IN_AAA(.(X0, X), Y, .(X0, Z)) → APP2_IN_AAA(X, Y, Z)
U4_GA(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_GA(X, X0, Y, perm_in_aa(Z, Y))
U4_GA(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → PERM_IN_AA(Z, Y)
PERM_IN_AA(X, .(X0, Y)) → U3_AA(X, X0, Y, app1_in_aga(X1, .(X0, X2), X))
PERM_IN_AA(X, .(X0, Y)) → APP1_IN_AGA(X1, .(X0, X2), X)
U3_AA(X, X0, Y, app1_out_aga(X1, .(X0, X2), X)) → U4_AA(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
U3_AA(X, X0, Y, app1_out_aga(X1, .(X0, X2), X)) → APP2_IN_GAA(X1, X2, Z)
U4_AA(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_AA(X, X0, Y, perm_in_aa(Z, Y))
U4_AA(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → PERM_IN_AA(Z, Y)

The TRS R consists of the following rules:

perm_in_ga(X, .(X0, Y)) → U3_ga(X, X0, Y, app1_in_agg(X1, .(X0, X2), X))
app1_in_agg(.(X0, X), Y, .(X0, Z)) → U1_agg(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga(.(X0, X), Y, .(X0, Z)) → U1_aga(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga([], Y, Y) → app1_out_aga([], Y, Y)
U1_aga(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_aga(.(X0, X), Y, .(X0, Z))
U1_agg(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_agg(.(X0, X), Y, .(X0, Z))
app1_in_agg([], Y, Y) → app1_out_agg([], Y, Y)
U3_ga(X, X0, Y, app1_out_agg(X1, .(X0, X2), X)) → U4_ga(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
app2_in_gaa(.(X0, X), Y, .(X0, Z)) → U2_gaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa(.(X0, X), Y, .(X0, Z)) → U2_aaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa([], Y, Y) → app2_out_aaa([], Y, Y)
U2_aaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_aaa(.(X0, X), Y, .(X0, Z))
U2_gaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_gaa(.(X0, X), Y, .(X0, Z))
app2_in_gaa([], Y, Y) → app2_out_gaa([], Y, Y)
U4_ga(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_ga(X, X0, Y, perm_in_aa(Z, Y))
perm_in_aa(X, .(X0, Y)) → U3_aa(X, X0, Y, app1_in_aga(X1, .(X0, X2), X))
U3_aa(X, X0, Y, app1_out_aga(X1, .(X0, X2), X)) → U4_aa(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
U4_aa(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_aa(X, X0, Y, perm_in_aa(Z, Y))
perm_in_aa([], []) → perm_out_aa([], [])
U5_aa(X, X0, Y, perm_out_aa(Z, Y)) → perm_out_aa(X, .(X0, Y))
U5_ga(X, X0, Y, perm_out_aa(Z, Y)) → perm_out_ga(X, .(X0, Y))
perm_in_ga([], []) → perm_out_ga([], [])

The argument filtering Pi contains the following mapping:
perm_in_ga(x1, x2)  =  perm_in_ga(x1)
U3_ga(x1, x2, x3, x4)  =  U3_ga(x4)
app1_in_agg(x1, x2, x3)  =  app1_in_agg(x2, x3)
.(x1, x2)  =  .
U1_agg(x1, x2, x3, x4, x5)  =  U1_agg(x5)
app1_in_aga(x1, x2, x3)  =  app1_in_aga(x2)
U1_aga(x1, x2, x3, x4, x5)  =  U1_aga(x5)
app1_out_aga(x1, x2, x3)  =  app1_out_aga(x1, x3)
app1_out_agg(x1, x2, x3)  =  app1_out_agg(x1)
U4_ga(x1, x2, x3, x4, x5, x6)  =  U4_ga(x6)
app2_in_gaa(x1, x2, x3)  =  app2_in_gaa(x1)
U2_gaa(x1, x2, x3, x4, x5)  =  U2_gaa(x5)
app2_in_aaa(x1, x2, x3)  =  app2_in_aaa
U2_aaa(x1, x2, x3, x4, x5)  =  U2_aaa(x5)
app2_out_aaa(x1, x2, x3)  =  app2_out_aaa(x1)
app2_out_gaa(x1, x2, x3)  =  app2_out_gaa
[]  =  []
U5_ga(x1, x2, x3, x4)  =  U5_ga(x4)
perm_in_aa(x1, x2)  =  perm_in_aa
U3_aa(x1, x2, x3, x4)  =  U3_aa(x4)
U4_aa(x1, x2, x3, x4, x5, x6)  =  U4_aa(x1, x6)
U5_aa(x1, x2, x3, x4)  =  U5_aa(x1, x4)
perm_out_aa(x1, x2)  =  perm_out_aa(x1, x2)
perm_out_ga(x1, x2)  =  perm_out_ga(x2)
U5_AA(x1, x2, x3, x4)  =  U5_AA(x1, x4)
U2_GAA(x1, x2, x3, x4, x5)  =  U2_GAA(x5)
U4_AA(x1, x2, x3, x4, x5, x6)  =  U4_AA(x1, x6)
U3_GA(x1, x2, x3, x4)  =  U3_GA(x4)
APP1_IN_AGG(x1, x2, x3)  =  APP1_IN_AGG(x2, x3)
U5_GA(x1, x2, x3, x4)  =  U5_GA(x4)
U2_AAA(x1, x2, x3, x4, x5)  =  U2_AAA(x5)
APP2_IN_GAA(x1, x2, x3)  =  APP2_IN_GAA(x1)
U4_GA(x1, x2, x3, x4, x5, x6)  =  U4_GA(x6)
APP2_IN_AAA(x1, x2, x3)  =  APP2_IN_AAA
PERM_IN_AA(x1, x2)  =  PERM_IN_AA
APP1_IN_AGA(x1, x2, x3)  =  APP1_IN_AGA(x2)
PERM_IN_GA(x1, x2)  =  PERM_IN_GA(x1)
U1_AGG(x1, x2, x3, x4, x5)  =  U1_AGG(x5)
U1_AGA(x1, x2, x3, x4, x5)  =  U1_AGA(x5)
U3_AA(x1, x2, x3, x4)  =  U3_AA(x4)

We have to consider all (P,R,Pi)-chains
The approximation of the Dependency Graph [30] contains 3 SCCs with 15 less nodes.

↳ Prolog
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
        ↳ PiDP
          ↳ DependencyGraphProof
            ↳ AND
PiDP
                ↳ UsableRulesProof
              ↳ PiDP
              ↳ PiDP
  ↳ PrologToPiTRSProof

Pi DP problem:
The TRS P consists of the following rules:

APP2_IN_AAA(.(X0, X), Y, .(X0, Z)) → APP2_IN_AAA(X, Y, Z)

The TRS R consists of the following rules:

perm_in_ga(X, .(X0, Y)) → U3_ga(X, X0, Y, app1_in_agg(X1, .(X0, X2), X))
app1_in_agg(.(X0, X), Y, .(X0, Z)) → U1_agg(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga(.(X0, X), Y, .(X0, Z)) → U1_aga(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga([], Y, Y) → app1_out_aga([], Y, Y)
U1_aga(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_aga(.(X0, X), Y, .(X0, Z))
U1_agg(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_agg(.(X0, X), Y, .(X0, Z))
app1_in_agg([], Y, Y) → app1_out_agg([], Y, Y)
U3_ga(X, X0, Y, app1_out_agg(X1, .(X0, X2), X)) → U4_ga(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
app2_in_gaa(.(X0, X), Y, .(X0, Z)) → U2_gaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa(.(X0, X), Y, .(X0, Z)) → U2_aaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa([], Y, Y) → app2_out_aaa([], Y, Y)
U2_aaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_aaa(.(X0, X), Y, .(X0, Z))
U2_gaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_gaa(.(X0, X), Y, .(X0, Z))
app2_in_gaa([], Y, Y) → app2_out_gaa([], Y, Y)
U4_ga(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_ga(X, X0, Y, perm_in_aa(Z, Y))
perm_in_aa(X, .(X0, Y)) → U3_aa(X, X0, Y, app1_in_aga(X1, .(X0, X2), X))
U3_aa(X, X0, Y, app1_out_aga(X1, .(X0, X2), X)) → U4_aa(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
U4_aa(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_aa(X, X0, Y, perm_in_aa(Z, Y))
perm_in_aa([], []) → perm_out_aa([], [])
U5_aa(X, X0, Y, perm_out_aa(Z, Y)) → perm_out_aa(X, .(X0, Y))
U5_ga(X, X0, Y, perm_out_aa(Z, Y)) → perm_out_ga(X, .(X0, Y))
perm_in_ga([], []) → perm_out_ga([], [])

The argument filtering Pi contains the following mapping:
perm_in_ga(x1, x2)  =  perm_in_ga(x1)
U3_ga(x1, x2, x3, x4)  =  U3_ga(x4)
app1_in_agg(x1, x2, x3)  =  app1_in_agg(x2, x3)
.(x1, x2)  =  .
U1_agg(x1, x2, x3, x4, x5)  =  U1_agg(x5)
app1_in_aga(x1, x2, x3)  =  app1_in_aga(x2)
U1_aga(x1, x2, x3, x4, x5)  =  U1_aga(x5)
app1_out_aga(x1, x2, x3)  =  app1_out_aga(x1, x3)
app1_out_agg(x1, x2, x3)  =  app1_out_agg(x1)
U4_ga(x1, x2, x3, x4, x5, x6)  =  U4_ga(x6)
app2_in_gaa(x1, x2, x3)  =  app2_in_gaa(x1)
U2_gaa(x1, x2, x3, x4, x5)  =  U2_gaa(x5)
app2_in_aaa(x1, x2, x3)  =  app2_in_aaa
U2_aaa(x1, x2, x3, x4, x5)  =  U2_aaa(x5)
app2_out_aaa(x1, x2, x3)  =  app2_out_aaa(x1)
app2_out_gaa(x1, x2, x3)  =  app2_out_gaa
[]  =  []
U5_ga(x1, x2, x3, x4)  =  U5_ga(x4)
perm_in_aa(x1, x2)  =  perm_in_aa
U3_aa(x1, x2, x3, x4)  =  U3_aa(x4)
U4_aa(x1, x2, x3, x4, x5, x6)  =  U4_aa(x1, x6)
U5_aa(x1, x2, x3, x4)  =  U5_aa(x1, x4)
perm_out_aa(x1, x2)  =  perm_out_aa(x1, x2)
perm_out_ga(x1, x2)  =  perm_out_ga(x2)
APP2_IN_AAA(x1, x2, x3)  =  APP2_IN_AAA

We have to consider all (P,R,Pi)-chains
For (infinitary) constructor rewriting [30] we can delete all non-usable rules from R.

↳ Prolog
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
        ↳ PiDP
          ↳ DependencyGraphProof
            ↳ AND
              ↳ PiDP
                ↳ UsableRulesProof
PiDP
                    ↳ PiDPToQDPProof
              ↳ PiDP
              ↳ PiDP
  ↳ PrologToPiTRSProof

Pi DP problem:
The TRS P consists of the following rules:

APP2_IN_AAA(.(X0, X), Y, .(X0, Z)) → APP2_IN_AAA(X, Y, Z)

R is empty.
The argument filtering Pi contains the following mapping:
.(x1, x2)  =  .
APP2_IN_AAA(x1, x2, x3)  =  APP2_IN_AAA

We have to consider all (P,R,Pi)-chains
Transforming (infinitary) constructor rewriting Pi-DP problem [30] into ordinary QDP problem [15] by application of Pi.

↳ Prolog
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
        ↳ PiDP
          ↳ DependencyGraphProof
            ↳ AND
              ↳ PiDP
                ↳ UsableRulesProof
                  ↳ PiDP
                    ↳ PiDPToQDPProof
QDP
                        ↳ NonTerminationProof
              ↳ PiDP
              ↳ PiDP
  ↳ PrologToPiTRSProof

Q DP problem:
The TRS P consists of the following rules:

APP2_IN_AAAAPP2_IN_AAA

R is empty.
Q is empty.
We have to consider all (P,Q,R)-chains.
We used the non-termination processor [17] to show that the DP problem is infinite.
Found a loop by semiunifying a rule from P directly.

The TRS P consists of the following rules:

APP2_IN_AAAAPP2_IN_AAA

The TRS R consists of the following rules:none


s = APP2_IN_AAA evaluates to t =APP2_IN_AAA

Thus s starts an infinite chain as s semiunifies with t with the following substitutions:




Rewriting sequence

The DP semiunifies directly so there is only one rewrite step from APP2_IN_AAA to APP2_IN_AAA.





↳ Prolog
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
        ↳ PiDP
          ↳ DependencyGraphProof
            ↳ AND
              ↳ PiDP
PiDP
                ↳ UsableRulesProof
              ↳ PiDP
  ↳ PrologToPiTRSProof

Pi DP problem:
The TRS P consists of the following rules:

APP1_IN_AGA(.(X0, X), Y, .(X0, Z)) → APP1_IN_AGA(X, Y, Z)

The TRS R consists of the following rules:

perm_in_ga(X, .(X0, Y)) → U3_ga(X, X0, Y, app1_in_agg(X1, .(X0, X2), X))
app1_in_agg(.(X0, X), Y, .(X0, Z)) → U1_agg(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga(.(X0, X), Y, .(X0, Z)) → U1_aga(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga([], Y, Y) → app1_out_aga([], Y, Y)
U1_aga(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_aga(.(X0, X), Y, .(X0, Z))
U1_agg(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_agg(.(X0, X), Y, .(X0, Z))
app1_in_agg([], Y, Y) → app1_out_agg([], Y, Y)
U3_ga(X, X0, Y, app1_out_agg(X1, .(X0, X2), X)) → U4_ga(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
app2_in_gaa(.(X0, X), Y, .(X0, Z)) → U2_gaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa(.(X0, X), Y, .(X0, Z)) → U2_aaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa([], Y, Y) → app2_out_aaa([], Y, Y)
U2_aaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_aaa(.(X0, X), Y, .(X0, Z))
U2_gaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_gaa(.(X0, X), Y, .(X0, Z))
app2_in_gaa([], Y, Y) → app2_out_gaa([], Y, Y)
U4_ga(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_ga(X, X0, Y, perm_in_aa(Z, Y))
perm_in_aa(X, .(X0, Y)) → U3_aa(X, X0, Y, app1_in_aga(X1, .(X0, X2), X))
U3_aa(X, X0, Y, app1_out_aga(X1, .(X0, X2), X)) → U4_aa(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
U4_aa(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_aa(X, X0, Y, perm_in_aa(Z, Y))
perm_in_aa([], []) → perm_out_aa([], [])
U5_aa(X, X0, Y, perm_out_aa(Z, Y)) → perm_out_aa(X, .(X0, Y))
U5_ga(X, X0, Y, perm_out_aa(Z, Y)) → perm_out_ga(X, .(X0, Y))
perm_in_ga([], []) → perm_out_ga([], [])

The argument filtering Pi contains the following mapping:
perm_in_ga(x1, x2)  =  perm_in_ga(x1)
U3_ga(x1, x2, x3, x4)  =  U3_ga(x4)
app1_in_agg(x1, x2, x3)  =  app1_in_agg(x2, x3)
.(x1, x2)  =  .
U1_agg(x1, x2, x3, x4, x5)  =  U1_agg(x5)
app1_in_aga(x1, x2, x3)  =  app1_in_aga(x2)
U1_aga(x1, x2, x3, x4, x5)  =  U1_aga(x5)
app1_out_aga(x1, x2, x3)  =  app1_out_aga(x1, x3)
app1_out_agg(x1, x2, x3)  =  app1_out_agg(x1)
U4_ga(x1, x2, x3, x4, x5, x6)  =  U4_ga(x6)
app2_in_gaa(x1, x2, x3)  =  app2_in_gaa(x1)
U2_gaa(x1, x2, x3, x4, x5)  =  U2_gaa(x5)
app2_in_aaa(x1, x2, x3)  =  app2_in_aaa
U2_aaa(x1, x2, x3, x4, x5)  =  U2_aaa(x5)
app2_out_aaa(x1, x2, x3)  =  app2_out_aaa(x1)
app2_out_gaa(x1, x2, x3)  =  app2_out_gaa
[]  =  []
U5_ga(x1, x2, x3, x4)  =  U5_ga(x4)
perm_in_aa(x1, x2)  =  perm_in_aa
U3_aa(x1, x2, x3, x4)  =  U3_aa(x4)
U4_aa(x1, x2, x3, x4, x5, x6)  =  U4_aa(x1, x6)
U5_aa(x1, x2, x3, x4)  =  U5_aa(x1, x4)
perm_out_aa(x1, x2)  =  perm_out_aa(x1, x2)
perm_out_ga(x1, x2)  =  perm_out_ga(x2)
APP1_IN_AGA(x1, x2, x3)  =  APP1_IN_AGA(x2)

We have to consider all (P,R,Pi)-chains
For (infinitary) constructor rewriting [30] we can delete all non-usable rules from R.

↳ Prolog
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
        ↳ PiDP
          ↳ DependencyGraphProof
            ↳ AND
              ↳ PiDP
              ↳ PiDP
                ↳ UsableRulesProof
PiDP
                    ↳ PiDPToQDPProof
              ↳ PiDP
  ↳ PrologToPiTRSProof

Pi DP problem:
The TRS P consists of the following rules:

APP1_IN_AGA(.(X0, X), Y, .(X0, Z)) → APP1_IN_AGA(X, Y, Z)

R is empty.
The argument filtering Pi contains the following mapping:
.(x1, x2)  =  .
APP1_IN_AGA(x1, x2, x3)  =  APP1_IN_AGA(x2)

We have to consider all (P,R,Pi)-chains
Transforming (infinitary) constructor rewriting Pi-DP problem [30] into ordinary QDP problem [15] by application of Pi.

↳ Prolog
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
        ↳ PiDP
          ↳ DependencyGraphProof
            ↳ AND
              ↳ PiDP
              ↳ PiDP
                ↳ UsableRulesProof
                  ↳ PiDP
                    ↳ PiDPToQDPProof
QDP
                        ↳ NonTerminationProof
              ↳ PiDP
  ↳ PrologToPiTRSProof

Q DP problem:
The TRS P consists of the following rules:

APP1_IN_AGA(Y) → APP1_IN_AGA(Y)

R is empty.
Q is empty.
We have to consider all (P,Q,R)-chains.
We used the non-termination processor [17] to show that the DP problem is infinite.
Found a loop by semiunifying a rule from P directly.

The TRS P consists of the following rules:

APP1_IN_AGA(Y) → APP1_IN_AGA(Y)

The TRS R consists of the following rules:none


s = APP1_IN_AGA(Y) evaluates to t =APP1_IN_AGA(Y)

Thus s starts an infinite chain as s semiunifies with t with the following substitutions:




Rewriting sequence

The DP semiunifies directly so there is only one rewrite step from APP1_IN_AGA(Y) to APP1_IN_AGA(Y).





↳ Prolog
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
        ↳ PiDP
          ↳ DependencyGraphProof
            ↳ AND
              ↳ PiDP
              ↳ PiDP
PiDP
                ↳ UsableRulesProof
  ↳ PrologToPiTRSProof

Pi DP problem:
The TRS P consists of the following rules:

U4_AA(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → PERM_IN_AA(Z, Y)
PERM_IN_AA(X, .(X0, Y)) → U3_AA(X, X0, Y, app1_in_aga(X1, .(X0, X2), X))
U3_AA(X, X0, Y, app1_out_aga(X1, .(X0, X2), X)) → U4_AA(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))

The TRS R consists of the following rules:

perm_in_ga(X, .(X0, Y)) → U3_ga(X, X0, Y, app1_in_agg(X1, .(X0, X2), X))
app1_in_agg(.(X0, X), Y, .(X0, Z)) → U1_agg(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga(.(X0, X), Y, .(X0, Z)) → U1_aga(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga([], Y, Y) → app1_out_aga([], Y, Y)
U1_aga(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_aga(.(X0, X), Y, .(X0, Z))
U1_agg(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_agg(.(X0, X), Y, .(X0, Z))
app1_in_agg([], Y, Y) → app1_out_agg([], Y, Y)
U3_ga(X, X0, Y, app1_out_agg(X1, .(X0, X2), X)) → U4_ga(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
app2_in_gaa(.(X0, X), Y, .(X0, Z)) → U2_gaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa(.(X0, X), Y, .(X0, Z)) → U2_aaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa([], Y, Y) → app2_out_aaa([], Y, Y)
U2_aaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_aaa(.(X0, X), Y, .(X0, Z))
U2_gaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_gaa(.(X0, X), Y, .(X0, Z))
app2_in_gaa([], Y, Y) → app2_out_gaa([], Y, Y)
U4_ga(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_ga(X, X0, Y, perm_in_aa(Z, Y))
perm_in_aa(X, .(X0, Y)) → U3_aa(X, X0, Y, app1_in_aga(X1, .(X0, X2), X))
U3_aa(X, X0, Y, app1_out_aga(X1, .(X0, X2), X)) → U4_aa(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
U4_aa(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_aa(X, X0, Y, perm_in_aa(Z, Y))
perm_in_aa([], []) → perm_out_aa([], [])
U5_aa(X, X0, Y, perm_out_aa(Z, Y)) → perm_out_aa(X, .(X0, Y))
U5_ga(X, X0, Y, perm_out_aa(Z, Y)) → perm_out_ga(X, .(X0, Y))
perm_in_ga([], []) → perm_out_ga([], [])

The argument filtering Pi contains the following mapping:
perm_in_ga(x1, x2)  =  perm_in_ga(x1)
U3_ga(x1, x2, x3, x4)  =  U3_ga(x4)
app1_in_agg(x1, x2, x3)  =  app1_in_agg(x2, x3)
.(x1, x2)  =  .
U1_agg(x1, x2, x3, x4, x5)  =  U1_agg(x5)
app1_in_aga(x1, x2, x3)  =  app1_in_aga(x2)
U1_aga(x1, x2, x3, x4, x5)  =  U1_aga(x5)
app1_out_aga(x1, x2, x3)  =  app1_out_aga(x1, x3)
app1_out_agg(x1, x2, x3)  =  app1_out_agg(x1)
U4_ga(x1, x2, x3, x4, x5, x6)  =  U4_ga(x6)
app2_in_gaa(x1, x2, x3)  =  app2_in_gaa(x1)
U2_gaa(x1, x2, x3, x4, x5)  =  U2_gaa(x5)
app2_in_aaa(x1, x2, x3)  =  app2_in_aaa
U2_aaa(x1, x2, x3, x4, x5)  =  U2_aaa(x5)
app2_out_aaa(x1, x2, x3)  =  app2_out_aaa(x1)
app2_out_gaa(x1, x2, x3)  =  app2_out_gaa
[]  =  []
U5_ga(x1, x2, x3, x4)  =  U5_ga(x4)
perm_in_aa(x1, x2)  =  perm_in_aa
U3_aa(x1, x2, x3, x4)  =  U3_aa(x4)
U4_aa(x1, x2, x3, x4, x5, x6)  =  U4_aa(x1, x6)
U5_aa(x1, x2, x3, x4)  =  U5_aa(x1, x4)
perm_out_aa(x1, x2)  =  perm_out_aa(x1, x2)
perm_out_ga(x1, x2)  =  perm_out_ga(x2)
U4_AA(x1, x2, x3, x4, x5, x6)  =  U4_AA(x1, x6)
PERM_IN_AA(x1, x2)  =  PERM_IN_AA
U3_AA(x1, x2, x3, x4)  =  U3_AA(x4)

We have to consider all (P,R,Pi)-chains
For (infinitary) constructor rewriting [30] we can delete all non-usable rules from R.

↳ Prolog
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
        ↳ PiDP
          ↳ DependencyGraphProof
            ↳ AND
              ↳ PiDP
              ↳ PiDP
              ↳ PiDP
                ↳ UsableRulesProof
PiDP
                    ↳ PiDPToQDPProof
  ↳ PrologToPiTRSProof

Pi DP problem:
The TRS P consists of the following rules:

U4_AA(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → PERM_IN_AA(Z, Y)
PERM_IN_AA(X, .(X0, Y)) → U3_AA(X, X0, Y, app1_in_aga(X1, .(X0, X2), X))
U3_AA(X, X0, Y, app1_out_aga(X1, .(X0, X2), X)) → U4_AA(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))

The TRS R consists of the following rules:

app1_in_aga(.(X0, X), Y, .(X0, Z)) → U1_aga(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga([], Y, Y) → app1_out_aga([], Y, Y)
app2_in_gaa(.(X0, X), Y, .(X0, Z)) → U2_gaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_gaa([], Y, Y) → app2_out_gaa([], Y, Y)
U1_aga(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_aga(.(X0, X), Y, .(X0, Z))
U2_gaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_gaa(.(X0, X), Y, .(X0, Z))
app2_in_aaa(.(X0, X), Y, .(X0, Z)) → U2_aaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa([], Y, Y) → app2_out_aaa([], Y, Y)
U2_aaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_aaa(.(X0, X), Y, .(X0, Z))

The argument filtering Pi contains the following mapping:
.(x1, x2)  =  .
app1_in_aga(x1, x2, x3)  =  app1_in_aga(x2)
U1_aga(x1, x2, x3, x4, x5)  =  U1_aga(x5)
app1_out_aga(x1, x2, x3)  =  app1_out_aga(x1, x3)
app2_in_gaa(x1, x2, x3)  =  app2_in_gaa(x1)
U2_gaa(x1, x2, x3, x4, x5)  =  U2_gaa(x5)
app2_in_aaa(x1, x2, x3)  =  app2_in_aaa
U2_aaa(x1, x2, x3, x4, x5)  =  U2_aaa(x5)
app2_out_aaa(x1, x2, x3)  =  app2_out_aaa(x1)
app2_out_gaa(x1, x2, x3)  =  app2_out_gaa
[]  =  []
U4_AA(x1, x2, x3, x4, x5, x6)  =  U4_AA(x1, x6)
PERM_IN_AA(x1, x2)  =  PERM_IN_AA
U3_AA(x1, x2, x3, x4)  =  U3_AA(x4)

We have to consider all (P,R,Pi)-chains
Transforming (infinitary) constructor rewriting Pi-DP problem [30] into ordinary QDP problem [15] by application of Pi.

↳ Prolog
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
        ↳ PiDP
          ↳ DependencyGraphProof
            ↳ AND
              ↳ PiDP
              ↳ PiDP
              ↳ PiDP
                ↳ UsableRulesProof
                  ↳ PiDP
                    ↳ PiDPToQDPProof
QDP
                        ↳ Narrowing
  ↳ PrologToPiTRSProof

Q DP problem:
The TRS P consists of the following rules:

U3_AA(app1_out_aga(X1, X)) → U4_AA(X, app2_in_gaa(X1))
PERM_IN_AAU3_AA(app1_in_aga(.))
U4_AA(X, app2_out_gaa) → PERM_IN_AA

The TRS R consists of the following rules:

app1_in_aga(Y) → U1_aga(app1_in_aga(Y))
app1_in_aga(Y) → app1_out_aga([], Y)
app2_in_gaa(.) → U2_gaa(app2_in_aaa)
app2_in_gaa([]) → app2_out_gaa
U1_aga(app1_out_aga(X, Z)) → app1_out_aga(., .)
U2_gaa(app2_out_aaa(X)) → app2_out_gaa
app2_in_aaaU2_aaa(app2_in_aaa)
app2_in_aaaapp2_out_aaa([])
U2_aaa(app2_out_aaa(X)) → app2_out_aaa(.)

The set Q consists of the following terms:

app1_in_aga(x0)
app2_in_gaa(x0)
U1_aga(x0)
U2_gaa(x0)
app2_in_aaa
U2_aaa(x0)

We have to consider all (P,Q,R)-chains.
By narrowing [15] the rule PERM_IN_AAU3_AA(app1_in_aga(.)) at position [0] we obtained the following new rules:

PERM_IN_AAU3_AA(app1_out_aga([], .))
PERM_IN_AAU3_AA(U1_aga(app1_in_aga(.)))



↳ Prolog
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
        ↳ PiDP
          ↳ DependencyGraphProof
            ↳ AND
              ↳ PiDP
              ↳ PiDP
              ↳ PiDP
                ↳ UsableRulesProof
                  ↳ PiDP
                    ↳ PiDPToQDPProof
                      ↳ QDP
                        ↳ Narrowing
QDP
                            ↳ Narrowing
  ↳ PrologToPiTRSProof

Q DP problem:
The TRS P consists of the following rules:

U3_AA(app1_out_aga(X1, X)) → U4_AA(X, app2_in_gaa(X1))
PERM_IN_AAU3_AA(app1_out_aga([], .))
PERM_IN_AAU3_AA(U1_aga(app1_in_aga(.)))
U4_AA(X, app2_out_gaa) → PERM_IN_AA

The TRS R consists of the following rules:

app1_in_aga(Y) → U1_aga(app1_in_aga(Y))
app1_in_aga(Y) → app1_out_aga([], Y)
app2_in_gaa(.) → U2_gaa(app2_in_aaa)
app2_in_gaa([]) → app2_out_gaa
U1_aga(app1_out_aga(X, Z)) → app1_out_aga(., .)
U2_gaa(app2_out_aaa(X)) → app2_out_gaa
app2_in_aaaU2_aaa(app2_in_aaa)
app2_in_aaaapp2_out_aaa([])
U2_aaa(app2_out_aaa(X)) → app2_out_aaa(.)

The set Q consists of the following terms:

app1_in_aga(x0)
app2_in_gaa(x0)
U1_aga(x0)
U2_gaa(x0)
app2_in_aaa
U2_aaa(x0)

We have to consider all (P,Q,R)-chains.
By narrowing [15] the rule U3_AA(app1_out_aga(X1, X)) → U4_AA(X, app2_in_gaa(X1)) at position [1] we obtained the following new rules:

U3_AA(app1_out_aga([], y1)) → U4_AA(y1, app2_out_gaa)
U3_AA(app1_out_aga(., y1)) → U4_AA(y1, U2_gaa(app2_in_aaa))



↳ Prolog
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
        ↳ PiDP
          ↳ DependencyGraphProof
            ↳ AND
              ↳ PiDP
              ↳ PiDP
              ↳ PiDP
                ↳ UsableRulesProof
                  ↳ PiDP
                    ↳ PiDPToQDPProof
                      ↳ QDP
                        ↳ Narrowing
                          ↳ QDP
                            ↳ Narrowing
QDP
                                ↳ UsableRulesProof
  ↳ PrologToPiTRSProof

Q DP problem:
The TRS P consists of the following rules:

U3_AA(app1_out_aga([], y1)) → U4_AA(y1, app2_out_gaa)
PERM_IN_AAU3_AA(app1_out_aga([], .))
PERM_IN_AAU3_AA(U1_aga(app1_in_aga(.)))
U3_AA(app1_out_aga(., y1)) → U4_AA(y1, U2_gaa(app2_in_aaa))
U4_AA(X, app2_out_gaa) → PERM_IN_AA

The TRS R consists of the following rules:

app1_in_aga(Y) → U1_aga(app1_in_aga(Y))
app1_in_aga(Y) → app1_out_aga([], Y)
app2_in_gaa(.) → U2_gaa(app2_in_aaa)
app2_in_gaa([]) → app2_out_gaa
U1_aga(app1_out_aga(X, Z)) → app1_out_aga(., .)
U2_gaa(app2_out_aaa(X)) → app2_out_gaa
app2_in_aaaU2_aaa(app2_in_aaa)
app2_in_aaaapp2_out_aaa([])
U2_aaa(app2_out_aaa(X)) → app2_out_aaa(.)

The set Q consists of the following terms:

app1_in_aga(x0)
app2_in_gaa(x0)
U1_aga(x0)
U2_gaa(x0)
app2_in_aaa
U2_aaa(x0)

We have to consider all (P,Q,R)-chains.
As all Q-normal forms are R-normal forms we are in the innermost case. Hence, by the usable rules processor [15] we can delete all non-usable rules [17] from R.

↳ Prolog
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
        ↳ PiDP
          ↳ DependencyGraphProof
            ↳ AND
              ↳ PiDP
              ↳ PiDP
              ↳ PiDP
                ↳ UsableRulesProof
                  ↳ PiDP
                    ↳ PiDPToQDPProof
                      ↳ QDP
                        ↳ Narrowing
                          ↳ QDP
                            ↳ Narrowing
                              ↳ QDP
                                ↳ UsableRulesProof
QDP
                                    ↳ QReductionProof
  ↳ PrologToPiTRSProof

Q DP problem:
The TRS P consists of the following rules:

U3_AA(app1_out_aga([], y1)) → U4_AA(y1, app2_out_gaa)
PERM_IN_AAU3_AA(app1_out_aga([], .))
PERM_IN_AAU3_AA(U1_aga(app1_in_aga(.)))
U3_AA(app1_out_aga(., y1)) → U4_AA(y1, U2_gaa(app2_in_aaa))
U4_AA(X, app2_out_gaa) → PERM_IN_AA

The TRS R consists of the following rules:

app1_in_aga(Y) → U1_aga(app1_in_aga(Y))
app1_in_aga(Y) → app1_out_aga([], Y)
U1_aga(app1_out_aga(X, Z)) → app1_out_aga(., .)
app2_in_aaaU2_aaa(app2_in_aaa)
app2_in_aaaapp2_out_aaa([])
U2_gaa(app2_out_aaa(X)) → app2_out_gaa
U2_aaa(app2_out_aaa(X)) → app2_out_aaa(.)

The set Q consists of the following terms:

app1_in_aga(x0)
app2_in_gaa(x0)
U1_aga(x0)
U2_gaa(x0)
app2_in_aaa
U2_aaa(x0)

We have to consider all (P,Q,R)-chains.
We deleted the following terms from Q as each root-symbol of these terms does neither occur in P nor in R.

app2_in_gaa(x0)



↳ Prolog
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
        ↳ PiDP
          ↳ DependencyGraphProof
            ↳ AND
              ↳ PiDP
              ↳ PiDP
              ↳ PiDP
                ↳ UsableRulesProof
                  ↳ PiDP
                    ↳ PiDPToQDPProof
                      ↳ QDP
                        ↳ Narrowing
                          ↳ QDP
                            ↳ Narrowing
                              ↳ QDP
                                ↳ UsableRulesProof
                                  ↳ QDP
                                    ↳ QReductionProof
QDP
                                        ↳ NonTerminationProof
  ↳ PrologToPiTRSProof

Q DP problem:
The TRS P consists of the following rules:

PERM_IN_AAU3_AA(app1_out_aga([], .))
U3_AA(app1_out_aga([], y1)) → U4_AA(y1, app2_out_gaa)
PERM_IN_AAU3_AA(U1_aga(app1_in_aga(.)))
U4_AA(X, app2_out_gaa) → PERM_IN_AA
U3_AA(app1_out_aga(., y1)) → U4_AA(y1, U2_gaa(app2_in_aaa))

The TRS R consists of the following rules:

app1_in_aga(Y) → U1_aga(app1_in_aga(Y))
app1_in_aga(Y) → app1_out_aga([], Y)
U1_aga(app1_out_aga(X, Z)) → app1_out_aga(., .)
app2_in_aaaU2_aaa(app2_in_aaa)
app2_in_aaaapp2_out_aaa([])
U2_gaa(app2_out_aaa(X)) → app2_out_gaa
U2_aaa(app2_out_aaa(X)) → app2_out_aaa(.)

The set Q consists of the following terms:

app1_in_aga(x0)
U1_aga(x0)
U2_gaa(x0)
app2_in_aaa
U2_aaa(x0)

We have to consider all (P,Q,R)-chains.
We used the non-termination processor [17] to show that the DP problem is infinite.
Found a loop by narrowing to the left:

The TRS P consists of the following rules:

PERM_IN_AAU3_AA(app1_out_aga([], .))
U3_AA(app1_out_aga([], y1)) → U4_AA(y1, app2_out_gaa)
PERM_IN_AAU3_AA(U1_aga(app1_in_aga(.)))
U4_AA(X, app2_out_gaa) → PERM_IN_AA
U3_AA(app1_out_aga(., y1)) → U4_AA(y1, U2_gaa(app2_in_aaa))

The TRS R consists of the following rules:

app1_in_aga(Y) → U1_aga(app1_in_aga(Y))
app1_in_aga(Y) → app1_out_aga([], Y)
U1_aga(app1_out_aga(X, Z)) → app1_out_aga(., .)
app2_in_aaaU2_aaa(app2_in_aaa)
app2_in_aaaapp2_out_aaa([])
U2_gaa(app2_out_aaa(X)) → app2_out_gaa
U2_aaa(app2_out_aaa(X)) → app2_out_aaa(.)


s = U3_AA(app1_out_aga([], y1)) evaluates to t =U3_AA(app1_out_aga([], .))

Thus s starts an infinite chain as s semiunifies with t with the following substitutions:




Rewriting sequence

U3_AA(app1_out_aga([], y1))U4_AA(y1, app2_out_gaa)
with rule U3_AA(app1_out_aga([], y1')) → U4_AA(y1', app2_out_gaa) at position [] and matcher [y1' / y1]

U4_AA(y1, app2_out_gaa)PERM_IN_AA
with rule U4_AA(X, app2_out_gaa) → PERM_IN_AA at position [] and matcher [X / y1]

PERM_IN_AAU3_AA(app1_out_aga([], .))
with rule PERM_IN_AAU3_AA(app1_out_aga([], .))

Now applying the matcher to the start term leads to a term which is equal to the last term in the rewriting sequence


All these steps are and every following step will be a correct step w.r.t to Q.




We use the technique of [30]. With regard to the inferred argument filtering the predicates were used in the following modes:
perm_in: (b,f) (f,f)
app1_in: (f,b,b) (f,b,f)
app2_in: (b,f,f) (f,f,f)
Transforming Prolog into the following Term Rewriting System:
Pi-finite rewrite system:
The TRS R consists of the following rules:

perm_in_ga(X, .(X0, Y)) → U3_ga(X, X0, Y, app1_in_agg(X1, .(X0, X2), X))
app1_in_agg(.(X0, X), Y, .(X0, Z)) → U1_agg(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga(.(X0, X), Y, .(X0, Z)) → U1_aga(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga([], Y, Y) → app1_out_aga([], Y, Y)
U1_aga(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_aga(.(X0, X), Y, .(X0, Z))
U1_agg(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_agg(.(X0, X), Y, .(X0, Z))
app1_in_agg([], Y, Y) → app1_out_agg([], Y, Y)
U3_ga(X, X0, Y, app1_out_agg(X1, .(X0, X2), X)) → U4_ga(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
app2_in_gaa(.(X0, X), Y, .(X0, Z)) → U2_gaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa(.(X0, X), Y, .(X0, Z)) → U2_aaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa([], Y, Y) → app2_out_aaa([], Y, Y)
U2_aaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_aaa(.(X0, X), Y, .(X0, Z))
U2_gaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_gaa(.(X0, X), Y, .(X0, Z))
app2_in_gaa([], Y, Y) → app2_out_gaa([], Y, Y)
U4_ga(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_ga(X, X0, Y, perm_in_aa(Z, Y))
perm_in_aa(X, .(X0, Y)) → U3_aa(X, X0, Y, app1_in_aga(X1, .(X0, X2), X))
U3_aa(X, X0, Y, app1_out_aga(X1, .(X0, X2), X)) → U4_aa(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
U4_aa(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_aa(X, X0, Y, perm_in_aa(Z, Y))
perm_in_aa([], []) → perm_out_aa([], [])
U5_aa(X, X0, Y, perm_out_aa(Z, Y)) → perm_out_aa(X, .(X0, Y))
U5_ga(X, X0, Y, perm_out_aa(Z, Y)) → perm_out_ga(X, .(X0, Y))
perm_in_ga([], []) → perm_out_ga([], [])

The argument filtering Pi contains the following mapping:
perm_in_ga(x1, x2)  =  perm_in_ga(x1)
U3_ga(x1, x2, x3, x4)  =  U3_ga(x1, x4)
app1_in_agg(x1, x2, x3)  =  app1_in_agg(x2, x3)
.(x1, x2)  =  .
U1_agg(x1, x2, x3, x4, x5)  =  U1_agg(x3, x5)
app1_in_aga(x1, x2, x3)  =  app1_in_aga(x2)
U1_aga(x1, x2, x3, x4, x5)  =  U1_aga(x3, x5)
app1_out_aga(x1, x2, x3)  =  app1_out_aga(x1, x2, x3)
app1_out_agg(x1, x2, x3)  =  app1_out_agg(x1, x2, x3)
U4_ga(x1, x2, x3, x4, x5, x6)  =  U4_ga(x1, x6)
app2_in_gaa(x1, x2, x3)  =  app2_in_gaa(x1)
U2_gaa(x1, x2, x3, x4, x5)  =  U2_gaa(x5)
app2_in_aaa(x1, x2, x3)  =  app2_in_aaa
U2_aaa(x1, x2, x3, x4, x5)  =  U2_aaa(x5)
app2_out_aaa(x1, x2, x3)  =  app2_out_aaa(x1)
app2_out_gaa(x1, x2, x3)  =  app2_out_gaa(x1)
[]  =  []
U5_ga(x1, x2, x3, x4)  =  U5_ga(x1, x4)
perm_in_aa(x1, x2)  =  perm_in_aa
U3_aa(x1, x2, x3, x4)  =  U3_aa(x4)
U4_aa(x1, x2, x3, x4, x5, x6)  =  U4_aa(x1, x6)
U5_aa(x1, x2, x3, x4)  =  U5_aa(x1, x4)
perm_out_aa(x1, x2)  =  perm_out_aa(x1, x2)
perm_out_ga(x1, x2)  =  perm_out_ga(x1, x2)

Infinitary Constructor Rewriting Termination of PiTRS implies Termination of Prolog



↳ Prolog
  ↳ PrologToPiTRSProof
  ↳ PrologToPiTRSProof
PiTRS
      ↳ DependencyPairsProof

Pi-finite rewrite system:
The TRS R consists of the following rules:

perm_in_ga(X, .(X0, Y)) → U3_ga(X, X0, Y, app1_in_agg(X1, .(X0, X2), X))
app1_in_agg(.(X0, X), Y, .(X0, Z)) → U1_agg(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga(.(X0, X), Y, .(X0, Z)) → U1_aga(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga([], Y, Y) → app1_out_aga([], Y, Y)
U1_aga(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_aga(.(X0, X), Y, .(X0, Z))
U1_agg(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_agg(.(X0, X), Y, .(X0, Z))
app1_in_agg([], Y, Y) → app1_out_agg([], Y, Y)
U3_ga(X, X0, Y, app1_out_agg(X1, .(X0, X2), X)) → U4_ga(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
app2_in_gaa(.(X0, X), Y, .(X0, Z)) → U2_gaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa(.(X0, X), Y, .(X0, Z)) → U2_aaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa([], Y, Y) → app2_out_aaa([], Y, Y)
U2_aaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_aaa(.(X0, X), Y, .(X0, Z))
U2_gaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_gaa(.(X0, X), Y, .(X0, Z))
app2_in_gaa([], Y, Y) → app2_out_gaa([], Y, Y)
U4_ga(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_ga(X, X0, Y, perm_in_aa(Z, Y))
perm_in_aa(X, .(X0, Y)) → U3_aa(X, X0, Y, app1_in_aga(X1, .(X0, X2), X))
U3_aa(X, X0, Y, app1_out_aga(X1, .(X0, X2), X)) → U4_aa(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
U4_aa(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_aa(X, X0, Y, perm_in_aa(Z, Y))
perm_in_aa([], []) → perm_out_aa([], [])
U5_aa(X, X0, Y, perm_out_aa(Z, Y)) → perm_out_aa(X, .(X0, Y))
U5_ga(X, X0, Y, perm_out_aa(Z, Y)) → perm_out_ga(X, .(X0, Y))
perm_in_ga([], []) → perm_out_ga([], [])

The argument filtering Pi contains the following mapping:
perm_in_ga(x1, x2)  =  perm_in_ga(x1)
U3_ga(x1, x2, x3, x4)  =  U3_ga(x1, x4)
app1_in_agg(x1, x2, x3)  =  app1_in_agg(x2, x3)
.(x1, x2)  =  .
U1_agg(x1, x2, x3, x4, x5)  =  U1_agg(x3, x5)
app1_in_aga(x1, x2, x3)  =  app1_in_aga(x2)
U1_aga(x1, x2, x3, x4, x5)  =  U1_aga(x3, x5)
app1_out_aga(x1, x2, x3)  =  app1_out_aga(x1, x2, x3)
app1_out_agg(x1, x2, x3)  =  app1_out_agg(x1, x2, x3)
U4_ga(x1, x2, x3, x4, x5, x6)  =  U4_ga(x1, x6)
app2_in_gaa(x1, x2, x3)  =  app2_in_gaa(x1)
U2_gaa(x1, x2, x3, x4, x5)  =  U2_gaa(x5)
app2_in_aaa(x1, x2, x3)  =  app2_in_aaa
U2_aaa(x1, x2, x3, x4, x5)  =  U2_aaa(x5)
app2_out_aaa(x1, x2, x3)  =  app2_out_aaa(x1)
app2_out_gaa(x1, x2, x3)  =  app2_out_gaa(x1)
[]  =  []
U5_ga(x1, x2, x3, x4)  =  U5_ga(x1, x4)
perm_in_aa(x1, x2)  =  perm_in_aa
U3_aa(x1, x2, x3, x4)  =  U3_aa(x4)
U4_aa(x1, x2, x3, x4, x5, x6)  =  U4_aa(x1, x6)
U5_aa(x1, x2, x3, x4)  =  U5_aa(x1, x4)
perm_out_aa(x1, x2)  =  perm_out_aa(x1, x2)
perm_out_ga(x1, x2)  =  perm_out_ga(x1, x2)


Using Dependency Pairs [1,30] we result in the following initial DP problem:
Pi DP problem:
The TRS P consists of the following rules:

PERM_IN_GA(X, .(X0, Y)) → U3_GA(X, X0, Y, app1_in_agg(X1, .(X0, X2), X))
PERM_IN_GA(X, .(X0, Y)) → APP1_IN_AGG(X1, .(X0, X2), X)
APP1_IN_AGG(.(X0, X), Y, .(X0, Z)) → U1_AGG(X0, X, Y, Z, app1_in_aga(X, Y, Z))
APP1_IN_AGG(.(X0, X), Y, .(X0, Z)) → APP1_IN_AGA(X, Y, Z)
APP1_IN_AGA(.(X0, X), Y, .(X0, Z)) → U1_AGA(X0, X, Y, Z, app1_in_aga(X, Y, Z))
APP1_IN_AGA(.(X0, X), Y, .(X0, Z)) → APP1_IN_AGA(X, Y, Z)
U3_GA(X, X0, Y, app1_out_agg(X1, .(X0, X2), X)) → U4_GA(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
U3_GA(X, X0, Y, app1_out_agg(X1, .(X0, X2), X)) → APP2_IN_GAA(X1, X2, Z)
APP2_IN_GAA(.(X0, X), Y, .(X0, Z)) → U2_GAA(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
APP2_IN_GAA(.(X0, X), Y, .(X0, Z)) → APP2_IN_AAA(X, Y, Z)
APP2_IN_AAA(.(X0, X), Y, .(X0, Z)) → U2_AAA(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
APP2_IN_AAA(.(X0, X), Y, .(X0, Z)) → APP2_IN_AAA(X, Y, Z)
U4_GA(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_GA(X, X0, Y, perm_in_aa(Z, Y))
U4_GA(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → PERM_IN_AA(Z, Y)
PERM_IN_AA(X, .(X0, Y)) → U3_AA(X, X0, Y, app1_in_aga(X1, .(X0, X2), X))
PERM_IN_AA(X, .(X0, Y)) → APP1_IN_AGA(X1, .(X0, X2), X)
U3_AA(X, X0, Y, app1_out_aga(X1, .(X0, X2), X)) → U4_AA(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
U3_AA(X, X0, Y, app1_out_aga(X1, .(X0, X2), X)) → APP2_IN_GAA(X1, X2, Z)
U4_AA(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_AA(X, X0, Y, perm_in_aa(Z, Y))
U4_AA(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → PERM_IN_AA(Z, Y)

The TRS R consists of the following rules:

perm_in_ga(X, .(X0, Y)) → U3_ga(X, X0, Y, app1_in_agg(X1, .(X0, X2), X))
app1_in_agg(.(X0, X), Y, .(X0, Z)) → U1_agg(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga(.(X0, X), Y, .(X0, Z)) → U1_aga(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga([], Y, Y) → app1_out_aga([], Y, Y)
U1_aga(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_aga(.(X0, X), Y, .(X0, Z))
U1_agg(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_agg(.(X0, X), Y, .(X0, Z))
app1_in_agg([], Y, Y) → app1_out_agg([], Y, Y)
U3_ga(X, X0, Y, app1_out_agg(X1, .(X0, X2), X)) → U4_ga(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
app2_in_gaa(.(X0, X), Y, .(X0, Z)) → U2_gaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa(.(X0, X), Y, .(X0, Z)) → U2_aaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa([], Y, Y) → app2_out_aaa([], Y, Y)
U2_aaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_aaa(.(X0, X), Y, .(X0, Z))
U2_gaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_gaa(.(X0, X), Y, .(X0, Z))
app2_in_gaa([], Y, Y) → app2_out_gaa([], Y, Y)
U4_ga(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_ga(X, X0, Y, perm_in_aa(Z, Y))
perm_in_aa(X, .(X0, Y)) → U3_aa(X, X0, Y, app1_in_aga(X1, .(X0, X2), X))
U3_aa(X, X0, Y, app1_out_aga(X1, .(X0, X2), X)) → U4_aa(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
U4_aa(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_aa(X, X0, Y, perm_in_aa(Z, Y))
perm_in_aa([], []) → perm_out_aa([], [])
U5_aa(X, X0, Y, perm_out_aa(Z, Y)) → perm_out_aa(X, .(X0, Y))
U5_ga(X, X0, Y, perm_out_aa(Z, Y)) → perm_out_ga(X, .(X0, Y))
perm_in_ga([], []) → perm_out_ga([], [])

The argument filtering Pi contains the following mapping:
perm_in_ga(x1, x2)  =  perm_in_ga(x1)
U3_ga(x1, x2, x3, x4)  =  U3_ga(x1, x4)
app1_in_agg(x1, x2, x3)  =  app1_in_agg(x2, x3)
.(x1, x2)  =  .
U1_agg(x1, x2, x3, x4, x5)  =  U1_agg(x3, x5)
app1_in_aga(x1, x2, x3)  =  app1_in_aga(x2)
U1_aga(x1, x2, x3, x4, x5)  =  U1_aga(x3, x5)
app1_out_aga(x1, x2, x3)  =  app1_out_aga(x1, x2, x3)
app1_out_agg(x1, x2, x3)  =  app1_out_agg(x1, x2, x3)
U4_ga(x1, x2, x3, x4, x5, x6)  =  U4_ga(x1, x6)
app2_in_gaa(x1, x2, x3)  =  app2_in_gaa(x1)
U2_gaa(x1, x2, x3, x4, x5)  =  U2_gaa(x5)
app2_in_aaa(x1, x2, x3)  =  app2_in_aaa
U2_aaa(x1, x2, x3, x4, x5)  =  U2_aaa(x5)
app2_out_aaa(x1, x2, x3)  =  app2_out_aaa(x1)
app2_out_gaa(x1, x2, x3)  =  app2_out_gaa(x1)
[]  =  []
U5_ga(x1, x2, x3, x4)  =  U5_ga(x1, x4)
perm_in_aa(x1, x2)  =  perm_in_aa
U3_aa(x1, x2, x3, x4)  =  U3_aa(x4)
U4_aa(x1, x2, x3, x4, x5, x6)  =  U4_aa(x1, x6)
U5_aa(x1, x2, x3, x4)  =  U5_aa(x1, x4)
perm_out_aa(x1, x2)  =  perm_out_aa(x1, x2)
perm_out_ga(x1, x2)  =  perm_out_ga(x1, x2)
U5_AA(x1, x2, x3, x4)  =  U5_AA(x1, x4)
U2_GAA(x1, x2, x3, x4, x5)  =  U2_GAA(x5)
U4_AA(x1, x2, x3, x4, x5, x6)  =  U4_AA(x1, x6)
U3_GA(x1, x2, x3, x4)  =  U3_GA(x1, x4)
APP1_IN_AGG(x1, x2, x3)  =  APP1_IN_AGG(x2, x3)
U5_GA(x1, x2, x3, x4)  =  U5_GA(x1, x4)
U2_AAA(x1, x2, x3, x4, x5)  =  U2_AAA(x5)
APP2_IN_GAA(x1, x2, x3)  =  APP2_IN_GAA(x1)
U4_GA(x1, x2, x3, x4, x5, x6)  =  U4_GA(x1, x6)
APP2_IN_AAA(x1, x2, x3)  =  APP2_IN_AAA
PERM_IN_AA(x1, x2)  =  PERM_IN_AA
APP1_IN_AGA(x1, x2, x3)  =  APP1_IN_AGA(x2)
PERM_IN_GA(x1, x2)  =  PERM_IN_GA(x1)
U1_AGG(x1, x2, x3, x4, x5)  =  U1_AGG(x3, x5)
U1_AGA(x1, x2, x3, x4, x5)  =  U1_AGA(x3, x5)
U3_AA(x1, x2, x3, x4)  =  U3_AA(x4)

We have to consider all (P,R,Pi)-chains

↳ Prolog
  ↳ PrologToPiTRSProof
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
PiDP
          ↳ DependencyGraphProof

Pi DP problem:
The TRS P consists of the following rules:

PERM_IN_GA(X, .(X0, Y)) → U3_GA(X, X0, Y, app1_in_agg(X1, .(X0, X2), X))
PERM_IN_GA(X, .(X0, Y)) → APP1_IN_AGG(X1, .(X0, X2), X)
APP1_IN_AGG(.(X0, X), Y, .(X0, Z)) → U1_AGG(X0, X, Y, Z, app1_in_aga(X, Y, Z))
APP1_IN_AGG(.(X0, X), Y, .(X0, Z)) → APP1_IN_AGA(X, Y, Z)
APP1_IN_AGA(.(X0, X), Y, .(X0, Z)) → U1_AGA(X0, X, Y, Z, app1_in_aga(X, Y, Z))
APP1_IN_AGA(.(X0, X), Y, .(X0, Z)) → APP1_IN_AGA(X, Y, Z)
U3_GA(X, X0, Y, app1_out_agg(X1, .(X0, X2), X)) → U4_GA(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
U3_GA(X, X0, Y, app1_out_agg(X1, .(X0, X2), X)) → APP2_IN_GAA(X1, X2, Z)
APP2_IN_GAA(.(X0, X), Y, .(X0, Z)) → U2_GAA(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
APP2_IN_GAA(.(X0, X), Y, .(X0, Z)) → APP2_IN_AAA(X, Y, Z)
APP2_IN_AAA(.(X0, X), Y, .(X0, Z)) → U2_AAA(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
APP2_IN_AAA(.(X0, X), Y, .(X0, Z)) → APP2_IN_AAA(X, Y, Z)
U4_GA(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_GA(X, X0, Y, perm_in_aa(Z, Y))
U4_GA(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → PERM_IN_AA(Z, Y)
PERM_IN_AA(X, .(X0, Y)) → U3_AA(X, X0, Y, app1_in_aga(X1, .(X0, X2), X))
PERM_IN_AA(X, .(X0, Y)) → APP1_IN_AGA(X1, .(X0, X2), X)
U3_AA(X, X0, Y, app1_out_aga(X1, .(X0, X2), X)) → U4_AA(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
U3_AA(X, X0, Y, app1_out_aga(X1, .(X0, X2), X)) → APP2_IN_GAA(X1, X2, Z)
U4_AA(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_AA(X, X0, Y, perm_in_aa(Z, Y))
U4_AA(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → PERM_IN_AA(Z, Y)

The TRS R consists of the following rules:

perm_in_ga(X, .(X0, Y)) → U3_ga(X, X0, Y, app1_in_agg(X1, .(X0, X2), X))
app1_in_agg(.(X0, X), Y, .(X0, Z)) → U1_agg(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga(.(X0, X), Y, .(X0, Z)) → U1_aga(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga([], Y, Y) → app1_out_aga([], Y, Y)
U1_aga(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_aga(.(X0, X), Y, .(X0, Z))
U1_agg(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_agg(.(X0, X), Y, .(X0, Z))
app1_in_agg([], Y, Y) → app1_out_agg([], Y, Y)
U3_ga(X, X0, Y, app1_out_agg(X1, .(X0, X2), X)) → U4_ga(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
app2_in_gaa(.(X0, X), Y, .(X0, Z)) → U2_gaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa(.(X0, X), Y, .(X0, Z)) → U2_aaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa([], Y, Y) → app2_out_aaa([], Y, Y)
U2_aaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_aaa(.(X0, X), Y, .(X0, Z))
U2_gaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_gaa(.(X0, X), Y, .(X0, Z))
app2_in_gaa([], Y, Y) → app2_out_gaa([], Y, Y)
U4_ga(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_ga(X, X0, Y, perm_in_aa(Z, Y))
perm_in_aa(X, .(X0, Y)) → U3_aa(X, X0, Y, app1_in_aga(X1, .(X0, X2), X))
U3_aa(X, X0, Y, app1_out_aga(X1, .(X0, X2), X)) → U4_aa(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
U4_aa(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_aa(X, X0, Y, perm_in_aa(Z, Y))
perm_in_aa([], []) → perm_out_aa([], [])
U5_aa(X, X0, Y, perm_out_aa(Z, Y)) → perm_out_aa(X, .(X0, Y))
U5_ga(X, X0, Y, perm_out_aa(Z, Y)) → perm_out_ga(X, .(X0, Y))
perm_in_ga([], []) → perm_out_ga([], [])

The argument filtering Pi contains the following mapping:
perm_in_ga(x1, x2)  =  perm_in_ga(x1)
U3_ga(x1, x2, x3, x4)  =  U3_ga(x1, x4)
app1_in_agg(x1, x2, x3)  =  app1_in_agg(x2, x3)
.(x1, x2)  =  .
U1_agg(x1, x2, x3, x4, x5)  =  U1_agg(x3, x5)
app1_in_aga(x1, x2, x3)  =  app1_in_aga(x2)
U1_aga(x1, x2, x3, x4, x5)  =  U1_aga(x3, x5)
app1_out_aga(x1, x2, x3)  =  app1_out_aga(x1, x2, x3)
app1_out_agg(x1, x2, x3)  =  app1_out_agg(x1, x2, x3)
U4_ga(x1, x2, x3, x4, x5, x6)  =  U4_ga(x1, x6)
app2_in_gaa(x1, x2, x3)  =  app2_in_gaa(x1)
U2_gaa(x1, x2, x3, x4, x5)  =  U2_gaa(x5)
app2_in_aaa(x1, x2, x3)  =  app2_in_aaa
U2_aaa(x1, x2, x3, x4, x5)  =  U2_aaa(x5)
app2_out_aaa(x1, x2, x3)  =  app2_out_aaa(x1)
app2_out_gaa(x1, x2, x3)  =  app2_out_gaa(x1)
[]  =  []
U5_ga(x1, x2, x3, x4)  =  U5_ga(x1, x4)
perm_in_aa(x1, x2)  =  perm_in_aa
U3_aa(x1, x2, x3, x4)  =  U3_aa(x4)
U4_aa(x1, x2, x3, x4, x5, x6)  =  U4_aa(x1, x6)
U5_aa(x1, x2, x3, x4)  =  U5_aa(x1, x4)
perm_out_aa(x1, x2)  =  perm_out_aa(x1, x2)
perm_out_ga(x1, x2)  =  perm_out_ga(x1, x2)
U5_AA(x1, x2, x3, x4)  =  U5_AA(x1, x4)
U2_GAA(x1, x2, x3, x4, x5)  =  U2_GAA(x5)
U4_AA(x1, x2, x3, x4, x5, x6)  =  U4_AA(x1, x6)
U3_GA(x1, x2, x3, x4)  =  U3_GA(x1, x4)
APP1_IN_AGG(x1, x2, x3)  =  APP1_IN_AGG(x2, x3)
U5_GA(x1, x2, x3, x4)  =  U5_GA(x1, x4)
U2_AAA(x1, x2, x3, x4, x5)  =  U2_AAA(x5)
APP2_IN_GAA(x1, x2, x3)  =  APP2_IN_GAA(x1)
U4_GA(x1, x2, x3, x4, x5, x6)  =  U4_GA(x1, x6)
APP2_IN_AAA(x1, x2, x3)  =  APP2_IN_AAA
PERM_IN_AA(x1, x2)  =  PERM_IN_AA
APP1_IN_AGA(x1, x2, x3)  =  APP1_IN_AGA(x2)
PERM_IN_GA(x1, x2)  =  PERM_IN_GA(x1)
U1_AGG(x1, x2, x3, x4, x5)  =  U1_AGG(x3, x5)
U1_AGA(x1, x2, x3, x4, x5)  =  U1_AGA(x3, x5)
U3_AA(x1, x2, x3, x4)  =  U3_AA(x4)

We have to consider all (P,R,Pi)-chains
The approximation of the Dependency Graph [30] contains 3 SCCs with 15 less nodes.

↳ Prolog
  ↳ PrologToPiTRSProof
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
        ↳ PiDP
          ↳ DependencyGraphProof
            ↳ AND
PiDP
                ↳ UsableRulesProof
              ↳ PiDP
              ↳ PiDP

Pi DP problem:
The TRS P consists of the following rules:

APP2_IN_AAA(.(X0, X), Y, .(X0, Z)) → APP2_IN_AAA(X, Y, Z)

The TRS R consists of the following rules:

perm_in_ga(X, .(X0, Y)) → U3_ga(X, X0, Y, app1_in_agg(X1, .(X0, X2), X))
app1_in_agg(.(X0, X), Y, .(X0, Z)) → U1_agg(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga(.(X0, X), Y, .(X0, Z)) → U1_aga(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga([], Y, Y) → app1_out_aga([], Y, Y)
U1_aga(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_aga(.(X0, X), Y, .(X0, Z))
U1_agg(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_agg(.(X0, X), Y, .(X0, Z))
app1_in_agg([], Y, Y) → app1_out_agg([], Y, Y)
U3_ga(X, X0, Y, app1_out_agg(X1, .(X0, X2), X)) → U4_ga(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
app2_in_gaa(.(X0, X), Y, .(X0, Z)) → U2_gaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa(.(X0, X), Y, .(X0, Z)) → U2_aaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa([], Y, Y) → app2_out_aaa([], Y, Y)
U2_aaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_aaa(.(X0, X), Y, .(X0, Z))
U2_gaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_gaa(.(X0, X), Y, .(X0, Z))
app2_in_gaa([], Y, Y) → app2_out_gaa([], Y, Y)
U4_ga(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_ga(X, X0, Y, perm_in_aa(Z, Y))
perm_in_aa(X, .(X0, Y)) → U3_aa(X, X0, Y, app1_in_aga(X1, .(X0, X2), X))
U3_aa(X, X0, Y, app1_out_aga(X1, .(X0, X2), X)) → U4_aa(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
U4_aa(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_aa(X, X0, Y, perm_in_aa(Z, Y))
perm_in_aa([], []) → perm_out_aa([], [])
U5_aa(X, X0, Y, perm_out_aa(Z, Y)) → perm_out_aa(X, .(X0, Y))
U5_ga(X, X0, Y, perm_out_aa(Z, Y)) → perm_out_ga(X, .(X0, Y))
perm_in_ga([], []) → perm_out_ga([], [])

The argument filtering Pi contains the following mapping:
perm_in_ga(x1, x2)  =  perm_in_ga(x1)
U3_ga(x1, x2, x3, x4)  =  U3_ga(x1, x4)
app1_in_agg(x1, x2, x3)  =  app1_in_agg(x2, x3)
.(x1, x2)  =  .
U1_agg(x1, x2, x3, x4, x5)  =  U1_agg(x3, x5)
app1_in_aga(x1, x2, x3)  =  app1_in_aga(x2)
U1_aga(x1, x2, x3, x4, x5)  =  U1_aga(x3, x5)
app1_out_aga(x1, x2, x3)  =  app1_out_aga(x1, x2, x3)
app1_out_agg(x1, x2, x3)  =  app1_out_agg(x1, x2, x3)
U4_ga(x1, x2, x3, x4, x5, x6)  =  U4_ga(x1, x6)
app2_in_gaa(x1, x2, x3)  =  app2_in_gaa(x1)
U2_gaa(x1, x2, x3, x4, x5)  =  U2_gaa(x5)
app2_in_aaa(x1, x2, x3)  =  app2_in_aaa
U2_aaa(x1, x2, x3, x4, x5)  =  U2_aaa(x5)
app2_out_aaa(x1, x2, x3)  =  app2_out_aaa(x1)
app2_out_gaa(x1, x2, x3)  =  app2_out_gaa(x1)
[]  =  []
U5_ga(x1, x2, x3, x4)  =  U5_ga(x1, x4)
perm_in_aa(x1, x2)  =  perm_in_aa
U3_aa(x1, x2, x3, x4)  =  U3_aa(x4)
U4_aa(x1, x2, x3, x4, x5, x6)  =  U4_aa(x1, x6)
U5_aa(x1, x2, x3, x4)  =  U5_aa(x1, x4)
perm_out_aa(x1, x2)  =  perm_out_aa(x1, x2)
perm_out_ga(x1, x2)  =  perm_out_ga(x1, x2)
APP2_IN_AAA(x1, x2, x3)  =  APP2_IN_AAA

We have to consider all (P,R,Pi)-chains
For (infinitary) constructor rewriting [30] we can delete all non-usable rules from R.

↳ Prolog
  ↳ PrologToPiTRSProof
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
        ↳ PiDP
          ↳ DependencyGraphProof
            ↳ AND
              ↳ PiDP
                ↳ UsableRulesProof
PiDP
                    ↳ PiDPToQDPProof
              ↳ PiDP
              ↳ PiDP

Pi DP problem:
The TRS P consists of the following rules:

APP2_IN_AAA(.(X0, X), Y, .(X0, Z)) → APP2_IN_AAA(X, Y, Z)

R is empty.
The argument filtering Pi contains the following mapping:
.(x1, x2)  =  .
APP2_IN_AAA(x1, x2, x3)  =  APP2_IN_AAA

We have to consider all (P,R,Pi)-chains
Transforming (infinitary) constructor rewriting Pi-DP problem [30] into ordinary QDP problem [15] by application of Pi.

↳ Prolog
  ↳ PrologToPiTRSProof
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
        ↳ PiDP
          ↳ DependencyGraphProof
            ↳ AND
              ↳ PiDP
                ↳ UsableRulesProof
                  ↳ PiDP
                    ↳ PiDPToQDPProof
QDP
                        ↳ NonTerminationProof
              ↳ PiDP
              ↳ PiDP

Q DP problem:
The TRS P consists of the following rules:

APP2_IN_AAAAPP2_IN_AAA

R is empty.
Q is empty.
We have to consider all (P,Q,R)-chains.
We used the non-termination processor [17] to show that the DP problem is infinite.
Found a loop by semiunifying a rule from P directly.

The TRS P consists of the following rules:

APP2_IN_AAAAPP2_IN_AAA

The TRS R consists of the following rules:none


s = APP2_IN_AAA evaluates to t =APP2_IN_AAA

Thus s starts an infinite chain as s semiunifies with t with the following substitutions:




Rewriting sequence

The DP semiunifies directly so there is only one rewrite step from APP2_IN_AAA to APP2_IN_AAA.





↳ Prolog
  ↳ PrologToPiTRSProof
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
        ↳ PiDP
          ↳ DependencyGraphProof
            ↳ AND
              ↳ PiDP
PiDP
                ↳ UsableRulesProof
              ↳ PiDP

Pi DP problem:
The TRS P consists of the following rules:

APP1_IN_AGA(.(X0, X), Y, .(X0, Z)) → APP1_IN_AGA(X, Y, Z)

The TRS R consists of the following rules:

perm_in_ga(X, .(X0, Y)) → U3_ga(X, X0, Y, app1_in_agg(X1, .(X0, X2), X))
app1_in_agg(.(X0, X), Y, .(X0, Z)) → U1_agg(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga(.(X0, X), Y, .(X0, Z)) → U1_aga(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga([], Y, Y) → app1_out_aga([], Y, Y)
U1_aga(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_aga(.(X0, X), Y, .(X0, Z))
U1_agg(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_agg(.(X0, X), Y, .(X0, Z))
app1_in_agg([], Y, Y) → app1_out_agg([], Y, Y)
U3_ga(X, X0, Y, app1_out_agg(X1, .(X0, X2), X)) → U4_ga(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
app2_in_gaa(.(X0, X), Y, .(X0, Z)) → U2_gaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa(.(X0, X), Y, .(X0, Z)) → U2_aaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa([], Y, Y) → app2_out_aaa([], Y, Y)
U2_aaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_aaa(.(X0, X), Y, .(X0, Z))
U2_gaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_gaa(.(X0, X), Y, .(X0, Z))
app2_in_gaa([], Y, Y) → app2_out_gaa([], Y, Y)
U4_ga(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_ga(X, X0, Y, perm_in_aa(Z, Y))
perm_in_aa(X, .(X0, Y)) → U3_aa(X, X0, Y, app1_in_aga(X1, .(X0, X2), X))
U3_aa(X, X0, Y, app1_out_aga(X1, .(X0, X2), X)) → U4_aa(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
U4_aa(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_aa(X, X0, Y, perm_in_aa(Z, Y))
perm_in_aa([], []) → perm_out_aa([], [])
U5_aa(X, X0, Y, perm_out_aa(Z, Y)) → perm_out_aa(X, .(X0, Y))
U5_ga(X, X0, Y, perm_out_aa(Z, Y)) → perm_out_ga(X, .(X0, Y))
perm_in_ga([], []) → perm_out_ga([], [])

The argument filtering Pi contains the following mapping:
perm_in_ga(x1, x2)  =  perm_in_ga(x1)
U3_ga(x1, x2, x3, x4)  =  U3_ga(x1, x4)
app1_in_agg(x1, x2, x3)  =  app1_in_agg(x2, x3)
.(x1, x2)  =  .
U1_agg(x1, x2, x3, x4, x5)  =  U1_agg(x3, x5)
app1_in_aga(x1, x2, x3)  =  app1_in_aga(x2)
U1_aga(x1, x2, x3, x4, x5)  =  U1_aga(x3, x5)
app1_out_aga(x1, x2, x3)  =  app1_out_aga(x1, x2, x3)
app1_out_agg(x1, x2, x3)  =  app1_out_agg(x1, x2, x3)
U4_ga(x1, x2, x3, x4, x5, x6)  =  U4_ga(x1, x6)
app2_in_gaa(x1, x2, x3)  =  app2_in_gaa(x1)
U2_gaa(x1, x2, x3, x4, x5)  =  U2_gaa(x5)
app2_in_aaa(x1, x2, x3)  =  app2_in_aaa
U2_aaa(x1, x2, x3, x4, x5)  =  U2_aaa(x5)
app2_out_aaa(x1, x2, x3)  =  app2_out_aaa(x1)
app2_out_gaa(x1, x2, x3)  =  app2_out_gaa(x1)
[]  =  []
U5_ga(x1, x2, x3, x4)  =  U5_ga(x1, x4)
perm_in_aa(x1, x2)  =  perm_in_aa
U3_aa(x1, x2, x3, x4)  =  U3_aa(x4)
U4_aa(x1, x2, x3, x4, x5, x6)  =  U4_aa(x1, x6)
U5_aa(x1, x2, x3, x4)  =  U5_aa(x1, x4)
perm_out_aa(x1, x2)  =  perm_out_aa(x1, x2)
perm_out_ga(x1, x2)  =  perm_out_ga(x1, x2)
APP1_IN_AGA(x1, x2, x3)  =  APP1_IN_AGA(x2)

We have to consider all (P,R,Pi)-chains
For (infinitary) constructor rewriting [30] we can delete all non-usable rules from R.

↳ Prolog
  ↳ PrologToPiTRSProof
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
        ↳ PiDP
          ↳ DependencyGraphProof
            ↳ AND
              ↳ PiDP
              ↳ PiDP
                ↳ UsableRulesProof
PiDP
                    ↳ PiDPToQDPProof
              ↳ PiDP

Pi DP problem:
The TRS P consists of the following rules:

APP1_IN_AGA(.(X0, X), Y, .(X0, Z)) → APP1_IN_AGA(X, Y, Z)

R is empty.
The argument filtering Pi contains the following mapping:
.(x1, x2)  =  .
APP1_IN_AGA(x1, x2, x3)  =  APP1_IN_AGA(x2)

We have to consider all (P,R,Pi)-chains
Transforming (infinitary) constructor rewriting Pi-DP problem [30] into ordinary QDP problem [15] by application of Pi.

↳ Prolog
  ↳ PrologToPiTRSProof
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
        ↳ PiDP
          ↳ DependencyGraphProof
            ↳ AND
              ↳ PiDP
              ↳ PiDP
                ↳ UsableRulesProof
                  ↳ PiDP
                    ↳ PiDPToQDPProof
QDP
                        ↳ NonTerminationProof
              ↳ PiDP

Q DP problem:
The TRS P consists of the following rules:

APP1_IN_AGA(Y) → APP1_IN_AGA(Y)

R is empty.
Q is empty.
We have to consider all (P,Q,R)-chains.
We used the non-termination processor [17] to show that the DP problem is infinite.
Found a loop by semiunifying a rule from P directly.

The TRS P consists of the following rules:

APP1_IN_AGA(Y) → APP1_IN_AGA(Y)

The TRS R consists of the following rules:none


s = APP1_IN_AGA(Y) evaluates to t =APP1_IN_AGA(Y)

Thus s starts an infinite chain as s semiunifies with t with the following substitutions:




Rewriting sequence

The DP semiunifies directly so there is only one rewrite step from APP1_IN_AGA(Y) to APP1_IN_AGA(Y).





↳ Prolog
  ↳ PrologToPiTRSProof
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
        ↳ PiDP
          ↳ DependencyGraphProof
            ↳ AND
              ↳ PiDP
              ↳ PiDP
PiDP
                ↳ UsableRulesProof

Pi DP problem:
The TRS P consists of the following rules:

U4_AA(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → PERM_IN_AA(Z, Y)
PERM_IN_AA(X, .(X0, Y)) → U3_AA(X, X0, Y, app1_in_aga(X1, .(X0, X2), X))
U3_AA(X, X0, Y, app1_out_aga(X1, .(X0, X2), X)) → U4_AA(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))

The TRS R consists of the following rules:

perm_in_ga(X, .(X0, Y)) → U3_ga(X, X0, Y, app1_in_agg(X1, .(X0, X2), X))
app1_in_agg(.(X0, X), Y, .(X0, Z)) → U1_agg(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga(.(X0, X), Y, .(X0, Z)) → U1_aga(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga([], Y, Y) → app1_out_aga([], Y, Y)
U1_aga(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_aga(.(X0, X), Y, .(X0, Z))
U1_agg(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_agg(.(X0, X), Y, .(X0, Z))
app1_in_agg([], Y, Y) → app1_out_agg([], Y, Y)
U3_ga(X, X0, Y, app1_out_agg(X1, .(X0, X2), X)) → U4_ga(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
app2_in_gaa(.(X0, X), Y, .(X0, Z)) → U2_gaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa(.(X0, X), Y, .(X0, Z)) → U2_aaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa([], Y, Y) → app2_out_aaa([], Y, Y)
U2_aaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_aaa(.(X0, X), Y, .(X0, Z))
U2_gaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_gaa(.(X0, X), Y, .(X0, Z))
app2_in_gaa([], Y, Y) → app2_out_gaa([], Y, Y)
U4_ga(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_ga(X, X0, Y, perm_in_aa(Z, Y))
perm_in_aa(X, .(X0, Y)) → U3_aa(X, X0, Y, app1_in_aga(X1, .(X0, X2), X))
U3_aa(X, X0, Y, app1_out_aga(X1, .(X0, X2), X)) → U4_aa(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))
U4_aa(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → U5_aa(X, X0, Y, perm_in_aa(Z, Y))
perm_in_aa([], []) → perm_out_aa([], [])
U5_aa(X, X0, Y, perm_out_aa(Z, Y)) → perm_out_aa(X, .(X0, Y))
U5_ga(X, X0, Y, perm_out_aa(Z, Y)) → perm_out_ga(X, .(X0, Y))
perm_in_ga([], []) → perm_out_ga([], [])

The argument filtering Pi contains the following mapping:
perm_in_ga(x1, x2)  =  perm_in_ga(x1)
U3_ga(x1, x2, x3, x4)  =  U3_ga(x1, x4)
app1_in_agg(x1, x2, x3)  =  app1_in_agg(x2, x3)
.(x1, x2)  =  .
U1_agg(x1, x2, x3, x4, x5)  =  U1_agg(x3, x5)
app1_in_aga(x1, x2, x3)  =  app1_in_aga(x2)
U1_aga(x1, x2, x3, x4, x5)  =  U1_aga(x3, x5)
app1_out_aga(x1, x2, x3)  =  app1_out_aga(x1, x2, x3)
app1_out_agg(x1, x2, x3)  =  app1_out_agg(x1, x2, x3)
U4_ga(x1, x2, x3, x4, x5, x6)  =  U4_ga(x1, x6)
app2_in_gaa(x1, x2, x3)  =  app2_in_gaa(x1)
U2_gaa(x1, x2, x3, x4, x5)  =  U2_gaa(x5)
app2_in_aaa(x1, x2, x3)  =  app2_in_aaa
U2_aaa(x1, x2, x3, x4, x5)  =  U2_aaa(x5)
app2_out_aaa(x1, x2, x3)  =  app2_out_aaa(x1)
app2_out_gaa(x1, x2, x3)  =  app2_out_gaa(x1)
[]  =  []
U5_ga(x1, x2, x3, x4)  =  U5_ga(x1, x4)
perm_in_aa(x1, x2)  =  perm_in_aa
U3_aa(x1, x2, x3, x4)  =  U3_aa(x4)
U4_aa(x1, x2, x3, x4, x5, x6)  =  U4_aa(x1, x6)
U5_aa(x1, x2, x3, x4)  =  U5_aa(x1, x4)
perm_out_aa(x1, x2)  =  perm_out_aa(x1, x2)
perm_out_ga(x1, x2)  =  perm_out_ga(x1, x2)
U4_AA(x1, x2, x3, x4, x5, x6)  =  U4_AA(x1, x6)
PERM_IN_AA(x1, x2)  =  PERM_IN_AA
U3_AA(x1, x2, x3, x4)  =  U3_AA(x4)

We have to consider all (P,R,Pi)-chains
For (infinitary) constructor rewriting [30] we can delete all non-usable rules from R.

↳ Prolog
  ↳ PrologToPiTRSProof
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
        ↳ PiDP
          ↳ DependencyGraphProof
            ↳ AND
              ↳ PiDP
              ↳ PiDP
              ↳ PiDP
                ↳ UsableRulesProof
PiDP
                    ↳ PiDPToQDPProof

Pi DP problem:
The TRS P consists of the following rules:

U4_AA(X, X0, Y, X1, X2, app2_out_gaa(X1, X2, Z)) → PERM_IN_AA(Z, Y)
PERM_IN_AA(X, .(X0, Y)) → U3_AA(X, X0, Y, app1_in_aga(X1, .(X0, X2), X))
U3_AA(X, X0, Y, app1_out_aga(X1, .(X0, X2), X)) → U4_AA(X, X0, Y, X1, X2, app2_in_gaa(X1, X2, Z))

The TRS R consists of the following rules:

app1_in_aga(.(X0, X), Y, .(X0, Z)) → U1_aga(X0, X, Y, Z, app1_in_aga(X, Y, Z))
app1_in_aga([], Y, Y) → app1_out_aga([], Y, Y)
app2_in_gaa(.(X0, X), Y, .(X0, Z)) → U2_gaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_gaa([], Y, Y) → app2_out_gaa([], Y, Y)
U1_aga(X0, X, Y, Z, app1_out_aga(X, Y, Z)) → app1_out_aga(.(X0, X), Y, .(X0, Z))
U2_gaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_gaa(.(X0, X), Y, .(X0, Z))
app2_in_aaa(.(X0, X), Y, .(X0, Z)) → U2_aaa(X0, X, Y, Z, app2_in_aaa(X, Y, Z))
app2_in_aaa([], Y, Y) → app2_out_aaa([], Y, Y)
U2_aaa(X0, X, Y, Z, app2_out_aaa(X, Y, Z)) → app2_out_aaa(.(X0, X), Y, .(X0, Z))

The argument filtering Pi contains the following mapping:
.(x1, x2)  =  .
app1_in_aga(x1, x2, x3)  =  app1_in_aga(x2)
U1_aga(x1, x2, x3, x4, x5)  =  U1_aga(x3, x5)
app1_out_aga(x1, x2, x3)  =  app1_out_aga(x1, x2, x3)
app2_in_gaa(x1, x2, x3)  =  app2_in_gaa(x1)
U2_gaa(x1, x2, x3, x4, x5)  =  U2_gaa(x5)
app2_in_aaa(x1, x2, x3)  =  app2_in_aaa
U2_aaa(x1, x2, x3, x4, x5)  =  U2_aaa(x5)
app2_out_aaa(x1, x2, x3)  =  app2_out_aaa(x1)
app2_out_gaa(x1, x2, x3)  =  app2_out_gaa(x1)
[]  =  []
U4_AA(x1, x2, x3, x4, x5, x6)  =  U4_AA(x1, x6)
PERM_IN_AA(x1, x2)  =  PERM_IN_AA
U3_AA(x1, x2, x3, x4)  =  U3_AA(x4)

We have to consider all (P,R,Pi)-chains
Transforming (infinitary) constructor rewriting Pi-DP problem [30] into ordinary QDP problem [15] by application of Pi.

↳ Prolog
  ↳ PrologToPiTRSProof
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
        ↳ PiDP
          ↳ DependencyGraphProof
            ↳ AND
              ↳ PiDP
              ↳ PiDP
              ↳ PiDP
                ↳ UsableRulesProof
                  ↳ PiDP
                    ↳ PiDPToQDPProof
QDP
                        ↳ Narrowing

Q DP problem:
The TRS P consists of the following rules:

U4_AA(X, app2_out_gaa(X1)) → PERM_IN_AA
U3_AA(app1_out_aga(X1, ., X)) → U4_AA(X, app2_in_gaa(X1))
PERM_IN_AAU3_AA(app1_in_aga(.))

The TRS R consists of the following rules:

app1_in_aga(Y) → U1_aga(Y, app1_in_aga(Y))
app1_in_aga(Y) → app1_out_aga([], Y, Y)
app2_in_gaa(.) → U2_gaa(app2_in_aaa)
app2_in_gaa([]) → app2_out_gaa([])
U1_aga(Y, app1_out_aga(X, Y, Z)) → app1_out_aga(., Y, .)
U2_gaa(app2_out_aaa(X)) → app2_out_gaa(.)
app2_in_aaaU2_aaa(app2_in_aaa)
app2_in_aaaapp2_out_aaa([])
U2_aaa(app2_out_aaa(X)) → app2_out_aaa(.)

The set Q consists of the following terms:

app1_in_aga(x0)
app2_in_gaa(x0)
U1_aga(x0, x1)
U2_gaa(x0)
app2_in_aaa
U2_aaa(x0)

We have to consider all (P,Q,R)-chains.
By narrowing [15] the rule PERM_IN_AAU3_AA(app1_in_aga(.)) at position [0] we obtained the following new rules:

PERM_IN_AAU3_AA(U1_aga(., app1_in_aga(.)))
PERM_IN_AAU3_AA(app1_out_aga([], ., .))



↳ Prolog
  ↳ PrologToPiTRSProof
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
        ↳ PiDP
          ↳ DependencyGraphProof
            ↳ AND
              ↳ PiDP
              ↳ PiDP
              ↳ PiDP
                ↳ UsableRulesProof
                  ↳ PiDP
                    ↳ PiDPToQDPProof
                      ↳ QDP
                        ↳ Narrowing
QDP
                            ↳ Narrowing

Q DP problem:
The TRS P consists of the following rules:

U4_AA(X, app2_out_gaa(X1)) → PERM_IN_AA
U3_AA(app1_out_aga(X1, ., X)) → U4_AA(X, app2_in_gaa(X1))
PERM_IN_AAU3_AA(app1_out_aga([], ., .))
PERM_IN_AAU3_AA(U1_aga(., app1_in_aga(.)))

The TRS R consists of the following rules:

app1_in_aga(Y) → U1_aga(Y, app1_in_aga(Y))
app1_in_aga(Y) → app1_out_aga([], Y, Y)
app2_in_gaa(.) → U2_gaa(app2_in_aaa)
app2_in_gaa([]) → app2_out_gaa([])
U1_aga(Y, app1_out_aga(X, Y, Z)) → app1_out_aga(., Y, .)
U2_gaa(app2_out_aaa(X)) → app2_out_gaa(.)
app2_in_aaaU2_aaa(app2_in_aaa)
app2_in_aaaapp2_out_aaa([])
U2_aaa(app2_out_aaa(X)) → app2_out_aaa(.)

The set Q consists of the following terms:

app1_in_aga(x0)
app2_in_gaa(x0)
U1_aga(x0, x1)
U2_gaa(x0)
app2_in_aaa
U2_aaa(x0)

We have to consider all (P,Q,R)-chains.
By narrowing [15] the rule U3_AA(app1_out_aga(X1, ., X)) → U4_AA(X, app2_in_gaa(X1)) at position [1] we obtained the following new rules:

U3_AA(app1_out_aga([], ., y1)) → U4_AA(y1, app2_out_gaa([]))
U3_AA(app1_out_aga(., ., y1)) → U4_AA(y1, U2_gaa(app2_in_aaa))



↳ Prolog
  ↳ PrologToPiTRSProof
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
        ↳ PiDP
          ↳ DependencyGraphProof
            ↳ AND
              ↳ PiDP
              ↳ PiDP
              ↳ PiDP
                ↳ UsableRulesProof
                  ↳ PiDP
                    ↳ PiDPToQDPProof
                      ↳ QDP
                        ↳ Narrowing
                          ↳ QDP
                            ↳ Narrowing
QDP
                                ↳ UsableRulesProof

Q DP problem:
The TRS P consists of the following rules:

U3_AA(app1_out_aga([], ., y1)) → U4_AA(y1, app2_out_gaa([]))
U4_AA(X, app2_out_gaa(X1)) → PERM_IN_AA
U3_AA(app1_out_aga(., ., y1)) → U4_AA(y1, U2_gaa(app2_in_aaa))
PERM_IN_AAU3_AA(app1_out_aga([], ., .))
PERM_IN_AAU3_AA(U1_aga(., app1_in_aga(.)))

The TRS R consists of the following rules:

app1_in_aga(Y) → U1_aga(Y, app1_in_aga(Y))
app1_in_aga(Y) → app1_out_aga([], Y, Y)
app2_in_gaa(.) → U2_gaa(app2_in_aaa)
app2_in_gaa([]) → app2_out_gaa([])
U1_aga(Y, app1_out_aga(X, Y, Z)) → app1_out_aga(., Y, .)
U2_gaa(app2_out_aaa(X)) → app2_out_gaa(.)
app2_in_aaaU2_aaa(app2_in_aaa)
app2_in_aaaapp2_out_aaa([])
U2_aaa(app2_out_aaa(X)) → app2_out_aaa(.)

The set Q consists of the following terms:

app1_in_aga(x0)
app2_in_gaa(x0)
U1_aga(x0, x1)
U2_gaa(x0)
app2_in_aaa
U2_aaa(x0)

We have to consider all (P,Q,R)-chains.
As all Q-normal forms are R-normal forms we are in the innermost case. Hence, by the usable rules processor [15] we can delete all non-usable rules [17] from R.

↳ Prolog
  ↳ PrologToPiTRSProof
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
        ↳ PiDP
          ↳ DependencyGraphProof
            ↳ AND
              ↳ PiDP
              ↳ PiDP
              ↳ PiDP
                ↳ UsableRulesProof
                  ↳ PiDP
                    ↳ PiDPToQDPProof
                      ↳ QDP
                        ↳ Narrowing
                          ↳ QDP
                            ↳ Narrowing
                              ↳ QDP
                                ↳ UsableRulesProof
QDP
                                    ↳ QReductionProof

Q DP problem:
The TRS P consists of the following rules:

U3_AA(app1_out_aga([], ., y1)) → U4_AA(y1, app2_out_gaa([]))
U4_AA(X, app2_out_gaa(X1)) → PERM_IN_AA
U3_AA(app1_out_aga(., ., y1)) → U4_AA(y1, U2_gaa(app2_in_aaa))
PERM_IN_AAU3_AA(app1_out_aga([], ., .))
PERM_IN_AAU3_AA(U1_aga(., app1_in_aga(.)))

The TRS R consists of the following rules:

app2_in_aaaU2_aaa(app2_in_aaa)
app2_in_aaaapp2_out_aaa([])
U2_gaa(app2_out_aaa(X)) → app2_out_gaa(.)
U2_aaa(app2_out_aaa(X)) → app2_out_aaa(.)
app1_in_aga(Y) → U1_aga(Y, app1_in_aga(Y))
app1_in_aga(Y) → app1_out_aga([], Y, Y)
U1_aga(Y, app1_out_aga(X, Y, Z)) → app1_out_aga(., Y, .)

The set Q consists of the following terms:

app1_in_aga(x0)
app2_in_gaa(x0)
U1_aga(x0, x1)
U2_gaa(x0)
app2_in_aaa
U2_aaa(x0)

We have to consider all (P,Q,R)-chains.
We deleted the following terms from Q as each root-symbol of these terms does neither occur in P nor in R.

app2_in_gaa(x0)



↳ Prolog
  ↳ PrologToPiTRSProof
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
        ↳ PiDP
          ↳ DependencyGraphProof
            ↳ AND
              ↳ PiDP
              ↳ PiDP
              ↳ PiDP
                ↳ UsableRulesProof
                  ↳ PiDP
                    ↳ PiDPToQDPProof
                      ↳ QDP
                        ↳ Narrowing
                          ↳ QDP
                            ↳ Narrowing
                              ↳ QDP
                                ↳ UsableRulesProof
                                  ↳ QDP
                                    ↳ QReductionProof
QDP
                                        ↳ NonTerminationProof

Q DP problem:
The TRS P consists of the following rules:

U3_AA(app1_out_aga([], ., y1)) → U4_AA(y1, app2_out_gaa([]))
U4_AA(X, app2_out_gaa(X1)) → PERM_IN_AA
U3_AA(app1_out_aga(., ., y1)) → U4_AA(y1, U2_gaa(app2_in_aaa))
PERM_IN_AAU3_AA(app1_out_aga([], ., .))
PERM_IN_AAU3_AA(U1_aga(., app1_in_aga(.)))

The TRS R consists of the following rules:

app2_in_aaaU2_aaa(app2_in_aaa)
app2_in_aaaapp2_out_aaa([])
U2_gaa(app2_out_aaa(X)) → app2_out_gaa(.)
U2_aaa(app2_out_aaa(X)) → app2_out_aaa(.)
app1_in_aga(Y) → U1_aga(Y, app1_in_aga(Y))
app1_in_aga(Y) → app1_out_aga([], Y, Y)
U1_aga(Y, app1_out_aga(X, Y, Z)) → app1_out_aga(., Y, .)

The set Q consists of the following terms:

app1_in_aga(x0)
U1_aga(x0, x1)
U2_gaa(x0)
app2_in_aaa
U2_aaa(x0)

We have to consider all (P,Q,R)-chains.
We used the non-termination processor [17] to show that the DP problem is infinite.
Found a loop by narrowing to the left:

The TRS P consists of the following rules:

U3_AA(app1_out_aga([], ., y1)) → U4_AA(y1, app2_out_gaa([]))
U4_AA(X, app2_out_gaa(X1)) → PERM_IN_AA
U3_AA(app1_out_aga(., ., y1)) → U4_AA(y1, U2_gaa(app2_in_aaa))
PERM_IN_AAU3_AA(app1_out_aga([], ., .))
PERM_IN_AAU3_AA(U1_aga(., app1_in_aga(.)))

The TRS R consists of the following rules:

app2_in_aaaU2_aaa(app2_in_aaa)
app2_in_aaaapp2_out_aaa([])
U2_gaa(app2_out_aaa(X)) → app2_out_gaa(.)
U2_aaa(app2_out_aaa(X)) → app2_out_aaa(.)
app1_in_aga(Y) → U1_aga(Y, app1_in_aga(Y))
app1_in_aga(Y) → app1_out_aga([], Y, Y)
U1_aga(Y, app1_out_aga(X, Y, Z)) → app1_out_aga(., Y, .)


s = U4_AA(X, app2_out_gaa(X1)) evaluates to t =U4_AA(., app2_out_gaa([]))

Thus s starts an infinite chain as s semiunifies with t with the following substitutions:




Rewriting sequence

U4_AA(X, app2_out_gaa(X1))PERM_IN_AA
with rule U4_AA(X', app2_out_gaa(X1')) → PERM_IN_AA at position [] and matcher [X1' / X1, X' / X]

PERM_IN_AAU3_AA(app1_out_aga([], ., .))
with rule PERM_IN_AAU3_AA(app1_out_aga([], ., .)) at position [] and matcher [ ]

U3_AA(app1_out_aga([], ., .))U4_AA(., app2_out_gaa([]))
with rule U3_AA(app1_out_aga([], ., y1)) → U4_AA(y1, app2_out_gaa([]))

Now applying the matcher to the start term leads to a term which is equal to the last term in the rewriting sequence


All these steps are and every following step will be a correct step w.r.t to Q.